| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // The <code>chrome.bluetoothLowEnergy</code> API is used to communicate with | 5 // The <code>chrome.bluetoothLowEnergy</code> API is used to communicate with |
| 6 // Bluetooth Smart (Low Energy) devices using the | 6 // Bluetooth Smart (Low Energy) devices using the |
| 7 // <a href="https://developer.bluetooth.org/TechnologyOverview/Pages/GATT.aspx"> | 7 // <a href="https://developer.bluetooth.org/TechnologyOverview/Pages/GATT.aspx"> |
| 8 // Generic Attribute Profile (GATT)</a>. | 8 // Generic Attribute Profile (GATT)</a>. |
| 9 [use_movable_types=true] namespace bluetoothLowEnergy { | 9 namespace bluetoothLowEnergy { |
| 10 // Values representing the possible properties of a characteristic. | 10 // Values representing the possible properties of a characteristic. |
| 11 enum CharacteristicProperty {broadcast, read, writeWithoutResponse, write, | 11 enum CharacteristicProperty {broadcast, read, writeWithoutResponse, write, |
| 12 notify, indicate, authenticatedSignedWrites, | 12 notify, indicate, authenticatedSignedWrites, |
| 13 extendedProperties, reliableWrite, | 13 extendedProperties, reliableWrite, |
| 14 writableAuxiliaries}; | 14 writableAuxiliaries}; |
| 15 | 15 |
| 16 // Type of advertisement. If 'broadcast' is chosen, the sent advertisement | 16 // Type of advertisement. If 'broadcast' is chosen, the sent advertisement |
| 17 // type will be ADV_NONCONN_IND and the device will broadcast with a random | 17 // type will be ADV_NONCONN_IND and the device will broadcast with a random |
| 18 // MAC Address. If set to 'peripheral', the advertisement type will be | 18 // MAC Address. If set to 'peripheral', the advertisement type will be |
| 19 // ADV_IND or ADV_SCAN_IND and the device will broadcast with real Bluetooth | 19 // ADV_IND or ADV_SCAN_IND and the device will broadcast with real Bluetooth |
| (...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 362 | 362 |
| 363 // Fired when the value of a remote GATT characteristic descriptor changes, | 363 // Fired when the value of a remote GATT characteristic descriptor changes, |
| 364 // usually as a result of a read request. This event exists | 364 // usually as a result of a read request. This event exists |
| 365 // mostly for convenience and will always be sent after a successful | 365 // mostly for convenience and will always be sent after a successful |
| 366 // call to $(ref:readDescriptorValue). | 366 // call to $(ref:readDescriptorValue). |
| 367 // |descriptor| : The GATT characteristic descriptor whose value has | 367 // |descriptor| : The GATT characteristic descriptor whose value has |
| 368 // changed. | 368 // changed. |
| 369 static void onDescriptorValueChanged(Descriptor descriptor); | 369 static void onDescriptorValueChanged(Descriptor descriptor); |
| 370 }; | 370 }; |
| 371 }; | 371 }; |
| OLD | NEW |