OSDN Git Service

Restructure GATTC
authorJakub Pawlowski <jpawlowski@google.com>
Tue, 15 Mar 2016 22:35:00 +0000 (15:35 -0700)
committerAndre Eisenbach <eisenbach@google.com>
Tue, 22 Mar 2016 03:18:07 +0000 (20:18 -0700)
commit36b67072266468e4b4becc76c0ddbff6154bb12c
treef123c527c379cc74b0a40b41ab2a1eb000b19b48
parent1af906353999b8f25ddd1030803292a4c84087f6
Restructure GATTC

This patch changes how GATTC is structured. Up till now, it
contained tBTA_GATTC_CACHE and tBTA_GATTC_CACHE_ATTR. Those
structures were so ugly, someone hide them inside internal
header, to make sure noone would ever access them from outside
GATTC. They are now replaced with:
tBTA_GATTC_SERVICE,
tBTA_GATTC_CHARACTERISTIC,
tBTA_GATTC_DESCRIPTOR and
tBTA_GATTC_INCLUDED_SVC.

Those looks much better, and were made globally avaliable.
Thanks to way they're build, we no longer need set of access
methods, which were also very ugly:
BTA_GATTC_GetFirstChar
BTA_GATTC_GetNextChar
BTA_GATTC_GetFirstIncludedService
etc.

This patch breaks HID, DO NOT SUBMIT without HID refactor.

Bug: 27455533
Change-Id: Ic42cfff175e0cc1a0d8e1a1216e2b4b756cbf77d
bta/gatt/bta_gattc_api.c
bta/gatt/bta_gattc_cache.c
bta/gatt/bta_gattc_int.h
bta/include/bta_gatt_api.h