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

Side by Side Diff: device/bluetooth/dbus/bluetooth_gatt_attribute_value_delegate.h

Issue 1974633002: Implement DBus changes needed for notifications. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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_DBUS_BLUETOOTH_GATT_ATTRIBUTE_VALUE_DELEGATE_H_ 5 #ifndef DEVICE_BLUETOOTH_DBUS_BLUETOOTH_GATT_ATTRIBUTE_VALUE_DELEGATE_H_
6 #define DEVICE_BLUETOOTH_DBUS_BLUETOOTH_GATT_ATTRIBUTE_VALUE_DELEGATE_H_ 6 #define DEVICE_BLUETOOTH_DBUS_BLUETOOTH_GATT_ATTRIBUTE_VALUE_DELEGATE_H_
7 7
8 #include <cstdint> 8 #include <cstdint>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 26 matching lines...) Expand all
37 // that the value was successfully written. Invoke |error_callback| to 37 // that the value was successfully written. Invoke |error_callback| to
38 // report a failure to write the value. This can happen, for example, if the 38 // report a failure to write the value. This can happen, for example, if the
39 // attribute has no write permission set. Either callback should be 39 // attribute has no write permission set. Either callback should be
40 // invoked after a reasonable amount of time, since the request will time 40 // invoked after a reasonable amount of time, since the request will time
41 // out if left pending for too long causing a disconnection. 41 // out if left pending for too long causing a disconnection.
42 virtual void SetValue( 42 virtual void SetValue(
43 const std::vector<uint8_t>& value, 43 const std::vector<uint8_t>& value,
44 const base::Closure& callback, 44 const base::Closure& callback,
45 const device::BluetoothLocalGattService::Delegate::ErrorCallback& 45 const device::BluetoothLocalGattService::Delegate::ErrorCallback&
46 error_callback) = 0; 46 error_callback) = 0;
47
48 // This method will be called, when a remote device requests to start sending
49 // notifications for this characteristic. This will never be called for
50 // descriptors.
51 virtual void StartNotifications() = 0;
52
53 // This method will be called, when a remote device requests to stop sending
54 // notifications for this characteristic. This will never be called for
55 // descriptors.
56 virtual void StopNotifications() = 0;
47 }; 57 };
48 58
49 } // namespace bluez 59 } // namespace bluez
50 60
51 #endif // DEVICE_BLUETOOTH_DBUS_BLUETOOTH_GATT_ATTRIBUTE_VALUE_DELEGATE_H_ 61 #endif // DEVICE_BLUETOOTH_DBUS_BLUETOOTH_GATT_ATTRIBUTE_VALUE_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698