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

Side by Side Diff: device/bluetooth/bluetooth_local_gatt_characteristic.h

Issue 1915803002: Bluetooth class changes for implementing local GATT attributes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: magic values fix Created 4 years, 8 months 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 DEVICE_BLUETOOTH_BLUETOOTH_LOCAL_GATT_CHARACTERISTIC_H_ 5 #ifndef DEVICE_BLUETOOTH_BLUETOOTH_LOCAL_GATT_CHARACTERISTIC_H_
6 #define DEVICE_BLUETOOTH_BLUETOOTH_LOCAL_GATT_CHARACTERISTIC_H_ 6 #define DEVICE_BLUETOOTH_BLUETOOTH_LOCAL_GATT_CHARACTERISTIC_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 24 matching lines...) Expand all
35 // This method constructs a characteristic with UUID |uuid|, initial cached 35 // This method constructs a characteristic with UUID |uuid|, initial cached
36 // value |value|, properties |properties|, and permissions |permissions|. 36 // value |value|, properties |properties|, and permissions |permissions|.
37 // |value| will be cached and returned for read requests and automatically set 37 // |value| will be cached and returned for read requests and automatically set
38 // for write requests by default, unless an instance of 38 // for write requests by default, unless an instance of
39 // BluetoothRemoteGattService::Delegate has been provided to the associated 39 // BluetoothRemoteGattService::Delegate has been provided to the associated
40 // BluetoothRemoteGattService instance, in which case the delegate will handle 40 // BluetoothRemoteGattService instance, in which case the delegate will handle
41 // read and write requests. The service instance will contain this 41 // read and write requests. The service instance will contain this
42 // characteristic. 42 // characteristic.
43 // TODO(rkc): Investigate how to handle |PROPERTY_EXTENDED_PROPERTIES| 43 // TODO(rkc): Investigate how to handle |PROPERTY_EXTENDED_PROPERTIES|
44 // correctly. 44 // correctly.
45 static BluetoothLocalGattCharacteristic* Create( 45 static base::WeakPtr<BluetoothLocalGattCharacteristic> Create(
46 const BluetoothUUID& uuid, 46 const BluetoothUUID& uuid,
47 const std::vector<uint8_t>& value,
48 Properties properties, 47 Properties properties,
49 Permissions permissions, 48 Permissions permissions,
50 BluetoothLocalGattService* service); 49 BluetoothLocalGattService* service);
51 50
52 protected: 51 protected:
53 BluetoothLocalGattCharacteristic(); 52 BluetoothLocalGattCharacteristic();
54 ~BluetoothLocalGattCharacteristic() override; 53 ~BluetoothLocalGattCharacteristic() override;
55 54
56 private: 55 private:
57 DISALLOW_COPY_AND_ASSIGN(BluetoothLocalGattCharacteristic); 56 DISALLOW_COPY_AND_ASSIGN(BluetoothLocalGattCharacteristic);
58 }; 57 };
59 58
60 } // namespace device 59 } // namespace device
61 60
62 #endif // DEVICE_BLUETOOTH_BLUETOOTH_LOCAL_GATT_CHARACTERISTIC_H_ 61 #endif // DEVICE_BLUETOOTH_BLUETOOTH_LOCAL_GATT_CHARACTERISTIC_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698