Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(157)

Side by Side Diff: third_party/WebKit/Source/modules/bluetooth/BluetoothRemoteGATTCharacteristic.h

Issue 2474863004: bluetooth: Add characteristics to the device's attribute instance map (Closed)
Patch Set: clean up Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 BluetoothRemoteGATTCharacteristic_h 5 #ifndef BluetoothRemoteGATTCharacteristic_h
6 #define BluetoothRemoteGATTCharacteristic_h 6 #define BluetoothRemoteGATTCharacteristic_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 "core/dom/DOMArrayPiece.h" 10 #include "core/dom/DOMArrayPiece.h"
(...skipping 29 matching lines...) Expand all
40 USING_PRE_FINALIZER(BluetoothRemoteGATTCharacteristic, dispose); 40 USING_PRE_FINALIZER(BluetoothRemoteGATTCharacteristic, dispose);
41 DEFINE_WRAPPERTYPEINFO(); 41 DEFINE_WRAPPERTYPEINFO();
42 USING_GARBAGE_COLLECTED_MIXIN(BluetoothRemoteGATTCharacteristic); 42 USING_GARBAGE_COLLECTED_MIXIN(BluetoothRemoteGATTCharacteristic);
43 43
44 public: 44 public:
45 explicit BluetoothRemoteGATTCharacteristic( 45 explicit BluetoothRemoteGATTCharacteristic(
46 ExecutionContext*, 46 ExecutionContext*,
47 std::unique_ptr<WebBluetoothRemoteGATTCharacteristicInit>, 47 std::unique_ptr<WebBluetoothRemoteGATTCharacteristicInit>,
48 BluetoothRemoteGATTService*); 48 BluetoothRemoteGATTService*);
49 49
50 // Interface required by CallbackPromiseAdapter. 50 static BluetoothRemoteGATTCharacteristic* create(
51 using WebType = std::unique_ptr<WebBluetoothRemoteGATTCharacteristicInit>; 51 ExecutionContext*,
52 static BluetoothRemoteGATTCharacteristic* take(
53 ScriptPromiseResolver*,
54 std::unique_ptr<WebBluetoothRemoteGATTCharacteristicInit>, 52 std::unique_ptr<WebBluetoothRemoteGATTCharacteristicInit>,
55 BluetoothRemoteGATTService*); 53 BluetoothRemoteGATTService*);
56 54
57 // Save value. 55 // Save value.
58 void setValue(DOMDataView*); 56 void setValue(DOMDataView*);
59 57
60 // WebBluetoothRemoteGATTCharacteristic interface: 58 // WebBluetoothRemoteGATTCharacteristic interface:
61 void dispatchCharacteristicValueChanged(const WebVector<uint8_t>&) override; 59 void dispatchCharacteristicValueChanged(const WebVector<uint8_t>&) override;
62 60
63 // ActiveDOMObject interface. 61 // ActiveDOMObject interface.
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 std::unique_ptr<WebBluetoothRemoteGATTCharacteristicInit> m_webCharacteristic; 103 std::unique_ptr<WebBluetoothRemoteGATTCharacteristicInit> m_webCharacteristic;
106 Member<BluetoothRemoteGATTService> m_service; 104 Member<BluetoothRemoteGATTService> m_service;
107 bool m_stopped; 105 bool m_stopped;
108 Member<BluetoothCharacteristicProperties> m_properties; 106 Member<BluetoothCharacteristicProperties> m_properties;
109 Member<DOMDataView> m_value; 107 Member<DOMDataView> m_value;
110 }; 108 };
111 109
112 } // namespace blink 110 } // namespace blink
113 111
114 #endif // BluetoothRemoteGATTCharacteristic_h 112 #endif // BluetoothRemoteGATTCharacteristic_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698