Index: third_party/WebKit/public/platform/modules/bluetooth/web_bluetooth.mojom |
diff --git a/third_party/WebKit/public/platform/modules/bluetooth/web_bluetooth.mojom b/third_party/WebKit/public/platform/modules/bluetooth/web_bluetooth.mojom |
index bdd829d20c149f7dd8ee6fdac0c444e22373004f..6ba9d73cf3206ebe226c8bbddf58124a4190a796 100644 |
--- a/third_party/WebKit/public/platform/modules/bluetooth/web_bluetooth.mojom |
+++ b/third_party/WebKit/public/platform/modules/bluetooth/web_bluetooth.mojom |
@@ -68,6 +68,18 @@ enum WebBluetoothError { |
ENUM_MAX_VALUE = REQUEST_DEVICE_WITHOUT_FRAME, |
}; |
+// Enum to be used when querying for GATT Objects. |
+enum WebBluetoothQueryType { |
Jeffrey Yasskin
2016/04/25 17:26:11
Maybe s/Type/Quantity/, but it's not a big deal.
ortuno
2016/04/25 20:37:41
Done.
|
+ SINGLE, |
+ MULTIPLE |
+}; |
+ |
+struct WebBluetoothRemoteGATTCharacteristic { |
+ string instance_id; |
+ string? uuid; |
+ uint32 properties; |
+}; |
+ |
// TODO(ortuno): Define Bluetooth Service. |
// https://crbug.com/508771 |
@@ -79,6 +91,16 @@ interface WebBluetoothService { |
// a device disconnects. |
SetClient(associated WebBluetoothServiceClient client); |
+ // Returns the Characteristics of a GATT Service with |service_instance_id|. |
+ // If |single_characteristic| is true, only one characteristic will be |
+ // returned. |
+ RemoteServiceGetCharacteristics( |
+ string service_instance_id, |
+ WebBluetoothQueryType type, |
+ string? characteristics_uuid) => ( |
+ WebBluetoothError error, |
+ array<WebBluetoothRemoteGATTCharacteristic>? characteristics); |
+ |
// Reads the value for characteristic with |
// |characteristic_instance_id|. If the value is successfully read the |
// callback will be run with WebBluetoothError::SUCCESS and the |