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

Unified Diff: device/bluetooth/dbus/fake_bluetooth_gatt_characteristic_service_provider.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 side-by-side diff with in-line comments
Download patch
Index: device/bluetooth/dbus/fake_bluetooth_gatt_characteristic_service_provider.h
diff --git a/device/bluetooth/dbus/fake_bluetooth_gatt_characteristic_service_provider.h b/device/bluetooth/dbus/fake_bluetooth_gatt_characteristic_service_provider.h
index 584286b7b88f29dc0af6df6c6211df0b74716ca4..5b0225cd933c2e740bd04661b1354da961bb1ed7 100644
--- a/device/bluetooth/dbus/fake_bluetooth_gatt_characteristic_service_provider.h
+++ b/device/bluetooth/dbus/fake_bluetooth_gatt_characteristic_service_provider.h
@@ -50,9 +50,13 @@ class DEVICE_BLUETOOTH_EXPORT FakeBluetoothGattCharacteristicServiceProvider
const device::BluetoothLocalGattService::Delegate::ErrorCallback&
error_callback);
+ // Method to simulate starting and stopping notifications.
+ bool NotificationsChange(bool start);
+
const dbus::ObjectPath& object_path() const override;
const std::string& uuid() const { return uuid_; }
const dbus::ObjectPath& service_path() const { return service_path_; }
+ const std::vector<uint8_t>& sent_value() const { return sent_value_; }
private:
// D-Bus object path of the fake GATT characteristic.
@@ -67,6 +71,9 @@ class DEVICE_BLUETOOTH_EXPORT FakeBluetoothGattCharacteristicServiceProvider
// Object path of the service that this characteristic belongs to.
const dbus::ObjectPath service_path_;
+ // Value that was sent to the fake remote device.
+ std::vector<uint8_t> sent_value_;
+
// The delegate that method calls are passed on to.
std::unique_ptr<BluetoothGattAttributeValueDelegate> delegate_;

Powered by Google App Engine
This is Rietveld 408576698