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

Side by Side Diff: device/bluetooth/public/interfaces/adapter.mojom

Issue 2404623002: bluetooth: Add DeviceChanged logging in Device service. (Closed)
Patch Set: Move devices map, simplify initialization Created 4 years, 2 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
« no previous file with comments | « device/bluetooth/device.cc ('k') | device/bluetooth/public/interfaces/device.mojom » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 module bluetooth.mojom; 5 module bluetooth.mojom;
6 6
7 import "device/bluetooth/public/interfaces/device.mojom"; 7 import "device/bluetooth/public/interfaces/device.mojom";
8 8
9 struct AdapterInfo { 9 struct AdapterInfo {
10 string address; 10 string address;
(...skipping 20 matching lines...) Expand all
31 // Sets the client that listens for the adapter's events. 31 // Sets the client that listens for the adapter's events.
32 SetClient(AdapterClient client); 32 SetClient(AdapterClient client);
33 }; 33 };
34 34
35 interface AdapterClient { 35 interface AdapterClient {
36 // Called the first time a device is discovered. 36 // Called the first time a device is discovered.
37 DeviceAdded(DeviceInfo device); 37 DeviceAdded(DeviceInfo device);
38 38
39 // Called after the device hasn't been seen for 3 minutes. 39 // Called after the device hasn't been seen for 3 minutes.
40 DeviceRemoved(DeviceInfo device); 40 DeviceRemoved(DeviceInfo device);
41
42 // Called when one of the following properties of a device changes:
43 // Address, appearance, Bluetooth class, Inquiry RSSI, Inquiry TX Power,
44 // Service UUIDs, Connectionable state, Connection state, Pairing state,
45 // Trustable state.
46 // Generally called for each advertisement packet recevied, but this is not
47 // guaranteed on ChromeOS or Linux. Because the RSSI is always changing,
48 // it's very likely this will be called for each advertising packet.
49 DeviceChanged(DeviceInfo device);
41 }; 50 };
42 51
43 interface AdapterFactory { 52 interface AdapterFactory {
44 // Gets an Adapter interface. Returns null if Bluetooth is not supported. 53 // Gets an Adapter interface. Returns null if Bluetooth is not supported.
45 GetAdapter() => (Adapter? adapter); 54 GetAdapter() => (Adapter? adapter);
46 }; 55 };
OLDNEW
« no previous file with comments | « device/bluetooth/device.cc ('k') | device/bluetooth/public/interfaces/device.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698