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>
Wed, 16 Mar 2016 19:14:00 +0000 (19:14 +0000)
commit5204fd71b3ca799942c45a36548faeba4d89477d
tree7cccdd3767b061137739d79e860c8fa77110b5b0
parent6721232129f137ab024d9b95fc1094a714bc4c01
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