• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright 2021 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 /*
18  * Generated mock file from original source file
19  *   Functions generated:30
20  */
21 
22 #include <base/functional/bind.h>
23 #include <base/functional/callback.h>
24 
25 #include "bta/gatt/database.h"
26 #include "bta/include/bta_gatt_api.h"
27 #include "stack/include/gatt_api.h"
28 #include "test/common/mock_functions.h"
29 #include "types/bluetooth/uuid.h"
30 #include "types/bt_transport.h"
31 #include "types/raw_address.h"
32 
BTA_GATTC_Disable(void)33 void BTA_GATTC_Disable(void) { inc_func_call_count(__func__); }
BTA_GATTC_GetCharacteristic(uint16_t,uint16_t)34 const gatt::Characteristic* BTA_GATTC_GetCharacteristic(uint16_t /* conn_id */,
35                                                         uint16_t /* handle */) {
36   inc_func_call_count(__func__);
37   return nullptr;
38 }
BTA_GATTC_GetOwningCharacteristic(uint16_t,uint16_t)39 const gatt::Characteristic* BTA_GATTC_GetOwningCharacteristic(
40     uint16_t /* conn_id */, uint16_t /* handle */) {
41   inc_func_call_count(__func__);
42   return nullptr;
43 }
BTA_GATTC_GetDescriptor(uint16_t,uint16_t)44 const gatt::Descriptor* BTA_GATTC_GetDescriptor(uint16_t /* conn_id */,
45                                                 uint16_t /* handle */) {
46   inc_func_call_count(__func__);
47   return nullptr;
48 }
BTA_GATTC_GetOwningService(uint16_t,uint16_t)49 const gatt::Service* BTA_GATTC_GetOwningService(uint16_t /* conn_id */,
50                                                 uint16_t /* handle */) {
51   inc_func_call_count(__func__);
52   return nullptr;
53 }
BTA_GATTC_GetServices(uint16_t)54 const std::list<gatt::Service>* BTA_GATTC_GetServices(uint16_t /* conn_id */) {
55   inc_func_call_count(__func__);
56   return nullptr;
57 }
BTA_GATTC_DeregisterForNotifications(tGATT_IF,const RawAddress &,uint16_t)58 tGATT_STATUS BTA_GATTC_DeregisterForNotifications(tGATT_IF /* client_if */,
59                                                   const RawAddress& /* bda */,
60                                                   uint16_t /* handle */) {
61   inc_func_call_count(__func__);
62   return GATT_SUCCESS;
63 }
BTA_GATTC_RegisterForNotifications(tGATT_IF,const RawAddress &,uint16_t)64 tGATT_STATUS BTA_GATTC_RegisterForNotifications(tGATT_IF /* client_if */,
65                                                 const RawAddress& /* bda */,
66                                                 uint16_t /* handle */) {
67   inc_func_call_count(__func__);
68   return GATT_SUCCESS;
69 }
BTA_GATTC_AppDeregister(tGATT_IF)70 void BTA_GATTC_AppDeregister(tGATT_IF /* client_if */) {
71   inc_func_call_count(__func__);
72 }
BTA_GATTC_AppRegister(tBTA_GATTC_CBACK *,BtaAppRegisterCallback,bool)73 void BTA_GATTC_AppRegister(tBTA_GATTC_CBACK* /* p_client_cb */,
74                            BtaAppRegisterCallback /* cb */,
75                            bool /* eatt_support */) {
76   inc_func_call_count(__func__);
77 }
BTA_GATTC_CancelOpen(tGATT_IF,const RawAddress &,bool)78 void BTA_GATTC_CancelOpen(tGATT_IF /* client_if */,
79                           const RawAddress& /* remote_bda */,
80                           bool /* is_direct */) {
81   inc_func_call_count(__func__);
82 }
BTA_GATTC_Close(uint16_t)83 void BTA_GATTC_Close(uint16_t /* conn_id */) { inc_func_call_count(__func__); }
BTA_GATTC_ConfigureMTU(uint16_t,uint16_t)84 void BTA_GATTC_ConfigureMTU(uint16_t /* conn_id */, uint16_t /* mtu */) {
85   inc_func_call_count(__func__);
86 }
BTA_GATTC_ConfigureMTU(uint16_t,uint16_t,GATT_CONFIGURE_MTU_OP_CB,void *)87 void BTA_GATTC_ConfigureMTU(uint16_t /* conn_id */, uint16_t /* mtu */,
88                             GATT_CONFIGURE_MTU_OP_CB /* callback */,
89                             void* /* cb_data */) {
90   inc_func_call_count(__func__);
91 }
BTA_GATTC_DiscoverServiceByUuid(uint16_t,const bluetooth::Uuid &)92 void BTA_GATTC_DiscoverServiceByUuid(uint16_t /* conn_id */,
93                                      const bluetooth::Uuid& /* srvc_uuid */) {
94   inc_func_call_count(__func__);
95 }
BTA_GATTC_ExecuteWrite(uint16_t,bool)96 void BTA_GATTC_ExecuteWrite(uint16_t /* conn_id */, bool /* is_execute */) {
97   inc_func_call_count(__func__);
98 }
BTA_GATTC_GetGattDb(uint16_t,uint16_t,uint16_t,btgatt_db_element_t **,int *)99 void BTA_GATTC_GetGattDb(uint16_t /* conn_id */, uint16_t /* start_handle */,
100                          uint16_t /* end_handle */,
101                          btgatt_db_element_t** /* db */, int* /* count */) {
102   inc_func_call_count(__func__);
103 }
BTA_GATTC_Open(tGATT_IF,const RawAddress &,tBTM_BLE_CONN_TYPE,bool)104 void BTA_GATTC_Open(tGATT_IF /* client_if */,
105                     const RawAddress& /* remote_bda */,
106                     tBTM_BLE_CONN_TYPE /* connection_type */,
107                     bool /* opportunistic */) {
108   inc_func_call_count(__func__);
109 }
BTA_GATTC_Open(tGATT_IF,const RawAddress &,tBTM_BLE_CONN_TYPE,tBT_TRANSPORT,bool,uint8_t)110 void BTA_GATTC_Open(tGATT_IF /* client_if */,
111                     const RawAddress& /* remote_bda */,
112                     tBTM_BLE_CONN_TYPE /* connection_type */,
113                     tBT_TRANSPORT /* transport */, bool /* opportunistic */,
114                     uint8_t /* initiating_phys */) {
115   inc_func_call_count(__func__);
116 }
BTA_GATTC_Open(tGATT_IF,const RawAddress &,tBLE_ADDR_TYPE,tBTM_BLE_CONN_TYPE,tBT_TRANSPORT,bool,uint8_t)117 void BTA_GATTC_Open(tGATT_IF /* client_if */,
118                     const RawAddress& /* remote_bda */,
119                     tBLE_ADDR_TYPE /* addr_type */,
120                     tBTM_BLE_CONN_TYPE /* connection_type */,
121                     tBT_TRANSPORT /* transport */, bool /* opportunistic */,
122                     uint8_t /* initiating_phys */) {
123   inc_func_call_count(__func__);
124 }
BTA_GATTC_PrepareWrite(uint16_t,uint16_t,uint16_t,std::vector<uint8_t>,tGATT_AUTH_REQ,GATT_WRITE_OP_CB,void *)125 void BTA_GATTC_PrepareWrite(uint16_t /* conn_id */, uint16_t /* handle */,
126                             uint16_t /* offset */,
127                             std::vector<uint8_t> /* value */,
128                             tGATT_AUTH_REQ /* auth_req */,
129                             GATT_WRITE_OP_CB /* callback */,
130                             void* /* cb_data */) {
131   inc_func_call_count(__func__);
132 }
BTA_GATTC_ReadCharDescr(uint16_t,uint16_t,tGATT_AUTH_REQ,GATT_READ_OP_CB,void *)133 void BTA_GATTC_ReadCharDescr(uint16_t /* conn_id */, uint16_t /* handle */,
134                              tGATT_AUTH_REQ /* auth_req */,
135                              GATT_READ_OP_CB /* callback */,
136                              void* /* cb_data */) {
137   inc_func_call_count(__func__);
138 }
BTA_GATTC_ReadCharacteristic(uint16_t,uint16_t,tGATT_AUTH_REQ,GATT_READ_OP_CB,void *)139 void BTA_GATTC_ReadCharacteristic(uint16_t /* conn_id */, uint16_t /* handle */,
140                                   tGATT_AUTH_REQ /* auth_req */,
141                                   GATT_READ_OP_CB /* callback */,
142                                   void* /* cb_data */) {
143   inc_func_call_count(__func__);
144 }
BTA_GATTC_ReadMultiple(uint16_t,tBTA_GATTC_MULTI &,bool,tGATT_AUTH_REQ,GATT_READ_MULTI_OP_CB,void *)145 void BTA_GATTC_ReadMultiple(uint16_t /* conn_id */,
146                             tBTA_GATTC_MULTI& /* handles */,
147                             bool /* variable_len */,
148                             tGATT_AUTH_REQ /* auth_req */,
149                             GATT_READ_MULTI_OP_CB /* callback */,
150                             void* /* cb_data */) {
151   inc_func_call_count(__func__);
152 }
BTA_GATTC_ReadUsingCharUuid(uint16_t,const bluetooth::Uuid &,uint16_t,uint16_t,tGATT_AUTH_REQ,GATT_READ_OP_CB,void *)153 void BTA_GATTC_ReadUsingCharUuid(uint16_t /* conn_id */,
154                                  const bluetooth::Uuid& /* uuid */,
155                                  uint16_t /* s_handle */,
156                                  uint16_t /* e_handle */,
157                                  tGATT_AUTH_REQ /* auth_req */,
158                                  GATT_READ_OP_CB /* callback */,
159                                  void* /* cb_data */) {
160   inc_func_call_count(__func__);
161 }
BTA_GATTC_Refresh(const RawAddress &)162 void BTA_GATTC_Refresh(const RawAddress& /* remote_bda */) {
163   inc_func_call_count(__func__);
164 }
BTA_GATTC_SendIndConfirm(uint16_t,uint16_t)165 void BTA_GATTC_SendIndConfirm(uint16_t /* conn_id */, uint16_t /* cid */) {
166   inc_func_call_count(__func__);
167 }
BTA_GATTC_ServiceSearchAllRequest(uint16_t)168 void BTA_GATTC_ServiceSearchAllRequest(uint16_t /* conn_id */) {
169   inc_func_call_count(__func__);
170 }
BTA_GATTC_ServiceSearchRequest(uint16_t,bluetooth::Uuid)171 void BTA_GATTC_ServiceSearchRequest(uint16_t /* conn_id */,
172                                     bluetooth::Uuid /* p_srvc_uuid */) {
173   inc_func_call_count(__func__);
174 }
BTA_GATTC_WriteCharDescr(uint16_t,uint16_t,std::vector<uint8_t>,tGATT_AUTH_REQ,GATT_WRITE_OP_CB,void *)175 void BTA_GATTC_WriteCharDescr(uint16_t /* conn_id */, uint16_t /* handle */,
176                               std::vector<uint8_t> /* value */,
177                               tGATT_AUTH_REQ /* auth_req */,
178                               GATT_WRITE_OP_CB /* callback */,
179                               void* /* cb_data */) {
180   inc_func_call_count(__func__);
181 }
BTA_GATTC_WriteCharValue(uint16_t,uint16_t,tGATT_WRITE_TYPE,std::vector<uint8_t>,tGATT_AUTH_REQ,GATT_WRITE_OP_CB,void *)182 void BTA_GATTC_WriteCharValue(uint16_t /* conn_id */, uint16_t /* handle */,
183                               tGATT_WRITE_TYPE /* write_type */,
184                               std::vector<uint8_t> /* value */,
185                               tGATT_AUTH_REQ /* auth_req */,
186                               GATT_WRITE_OP_CB /* callback */,
187                               void* /* cb_data */) {
188   inc_func_call_count(__func__);
189 }
bta_gattc_continue_discovery_if_needed(const RawAddress &,uint16_t)190 void bta_gattc_continue_discovery_if_needed(const RawAddress& /* bd_addr */,
191                                             uint16_t /* acl_handle */) {
192   inc_func_call_count(__func__);
193 }
bta_gatt_client_dump(int)194 void bta_gatt_client_dump(int /* fd */) { inc_func_call_count(__func__); }
195