summaryrefslogtreecommitdiffstats
path: root/src/com/android/bluetooth/gatt/HandleMap.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/com/android/bluetooth/gatt/HandleMap.java')
-rw-r--r--src/com/android/bluetooth/gatt/HandleMap.java17
1 files changed, 15 insertions, 2 deletions
diff --git a/src/com/android/bluetooth/gatt/HandleMap.java b/src/com/android/bluetooth/gatt/HandleMap.java
index 5d45654b9..187625a43 100644
--- a/src/com/android/bluetooth/gatt/HandleMap.java
+++ b/src/com/android/bluetooth/gatt/HandleMap.java
@@ -42,6 +42,7 @@ class HandleMap {
int serviceHandle = 0;
int charHandle = 0;
boolean started = false;
+ boolean advertisePreferred = false;
Entry(int serverIf, int handle, UUID uuid, int serviceType, int instance) {
this.serverIf = serverIf;
@@ -52,6 +53,17 @@ class HandleMap {
this.serviceType = serviceType;
}
+ Entry(int serverIf, int handle, UUID uuid, int serviceType, int instance,
+ boolean advertisePreferred) {
+ this.serverIf = serverIf;
+ this.type = TYPE_SERVICE;
+ this.handle = handle;
+ this.uuid = uuid;
+ this.instance = instance;
+ this.serviceType = serviceType;
+ this.advertisePreferred = advertisePreferred;
+ }
+
Entry(int serverIf, int type, int handle, UUID uuid, int serviceHandle) {
this.serverIf = serverIf;
this.type = type;
@@ -86,8 +98,9 @@ class HandleMap {
mRequestMap.clear();
}
- void addService(int serverIf, int handle, UUID uuid, int serviceType, int instance) {
- mEntries.add(new Entry(serverIf, handle, uuid, serviceType, instance));
+ void addService(int serverIf, int handle, UUID uuid, int serviceType, int instance,
+ boolean advertisePreferred) {
+ mEntries.add(new Entry(serverIf, handle, uuid, serviceType, instance, advertisePreferred));
}
void addCharacteristic(int serverIf, int handle, UUID uuid, int serviceHandle) {