| 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 #ifndef BluetoothDevice_h | 5 #ifndef BluetoothDevice_h |
| 6 #define BluetoothDevice_h | 6 #define BluetoothDevice_h |
| 7 | 7 |
| 8 #include "bindings/core/v8/ScriptWrappable.h" | 8 #include "bindings/core/v8/ScriptWrappable.h" |
| 9 #include "core/dom/ActiveDOMObject.h" | 9 #include "core/dom/ActiveDOMObject.h" |
| 10 #include "modules/EventTargetModules.h" | 10 #include "modules/EventTargetModules.h" |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 const AtomicString& interfaceName() const override; | 66 const AtomicString& interfaceName() const override; |
| 67 ExecutionContext* getExecutionContext() const override; | 67 ExecutionContext* getExecutionContext() const override; |
| 68 | 68 |
| 69 // Interface required by Garbage Collection: | 69 // Interface required by Garbage Collection: |
| 70 DECLARE_VIRTUAL_TRACE(); | 70 DECLARE_VIRTUAL_TRACE(); |
| 71 | 71 |
| 72 // IDL exposed interface: | 72 // IDL exposed interface: |
| 73 String id() { return m_webDevice->id; } | 73 String id() { return m_webDevice->id; } |
| 74 String name() { return m_webDevice->name; } | 74 String name() { return m_webDevice->name; } |
| 75 BluetoothAdvertisingData* adData() { return m_adData; } | 75 BluetoothAdvertisingData* adData() { return m_adData; } |
| 76 unsigned deviceClass(bool& isNull); | |
| 77 String vendorIDSource(); | |
| 78 unsigned vendorID(bool& isNull); | |
| 79 unsigned productID(bool& isNull); | |
| 80 unsigned productVersion(bool& isNull); | |
| 81 BluetoothRemoteGATTServer* gatt() { return m_gatt; } | 76 BluetoothRemoteGATTServer* gatt() { return m_gatt; } |
| 82 Vector<String> uuids(); | 77 Vector<String> uuids(); |
| 83 // TODO(ortuno): Remove connectGATT | 78 // TODO(ortuno): Remove connectGATT |
| 84 // http://crbug.com/582292 | 79 // http://crbug.com/582292 |
| 85 ScriptPromise connectGATT(ScriptState*); | 80 ScriptPromise connectGATT(ScriptState*); |
| 86 | 81 |
| 87 DEFINE_ATTRIBUTE_EVENT_LISTENER(gattserverdisconnected); | 82 DEFINE_ATTRIBUTE_EVENT_LISTENER(gattserverdisconnected); |
| 88 | 83 |
| 89 private: | 84 private: |
| 90 OwnPtr<WebBluetoothDevice> m_webDevice; | 85 OwnPtr<WebBluetoothDevice> m_webDevice; |
| 91 Member<BluetoothAdvertisingData> m_adData; | 86 Member<BluetoothAdvertisingData> m_adData; |
| 92 Member<BluetoothRemoteGATTServer> m_gatt; | 87 Member<BluetoothRemoteGATTServer> m_gatt; |
| 93 }; | 88 }; |
| 94 | 89 |
| 95 } // namespace blink | 90 } // namespace blink |
| 96 | 91 |
| 97 #endif // BluetoothDevice_h | 92 #endif // BluetoothDevice_h |
| OLD | NEW |