• 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:10
20  *
21  *  mockcify.pl ver 0.2
22  */
23 
24 #include <base/functional/callback.h>
25 
26 #include <functional>
27 
28 // Original included files, if any
29 #include "stack/btm/security_device_record.h"
30 #include "types/ble_address_with_type.h"
31 #include "types/raw_address.h"
32 
33 // Mocked compile conditionals, if any
34 namespace test {
35 namespace mock {
36 namespace stack_btm_ble_addr {
37 
38 // Name: btm_ble_addr_resolvable
39 // Params: const RawAddress& rpa, tBTM_SEC_DEV_REC* p_dev_rec
40 // Returns: bool
41 struct btm_ble_addr_resolvable {
42   std::function<bool(const RawAddress& rpa, tBTM_SEC_DEV_REC* p_dev_rec)> body{
43           [](const RawAddress& /* rpa */, tBTM_SEC_DEV_REC* /* p_dev_rec */) { return false; }};
operatorbtm_ble_addr_resolvable44   bool operator()(const RawAddress& rpa, tBTM_SEC_DEV_REC* p_dev_rec) {
45     return body(rpa, p_dev_rec);
46   }
47 };
48 extern struct btm_ble_addr_resolvable btm_ble_addr_resolvable;
49 // Name: btm_ble_resolve_random_addr
50 // Params: const RawAddress& random_bda
51 // Returns: tBTM_SEC_DEV_REC*
52 struct btm_ble_resolve_random_addr {
53   std::function<tBTM_SEC_DEV_REC*(const RawAddress& random_bda)> body{
54           [](const RawAddress& /* random_bda */) { return nullptr; }};
operatorbtm_ble_resolve_random_addr55   tBTM_SEC_DEV_REC* operator()(const RawAddress& random_bda) { return body(random_bda); }
56 };
57 extern struct btm_ble_resolve_random_addr btm_ble_resolve_random_addr;
58 // Name: btm_identity_addr_to_random_pseudo
59 // Params: RawAddress* bd_addr, uint8_t* p_addr_type, bool refresh
60 // Returns: bool
61 struct btm_identity_addr_to_random_pseudo {
62   std::function<bool(RawAddress* bd_addr, tBLE_ADDR_TYPE* p_addr_type, bool refresh)> body{
63           [](RawAddress* /* bd_addr */, tBLE_ADDR_TYPE* /* p_addr_type */, bool /* refresh */) {
64             return false;
65           }};
operatorbtm_identity_addr_to_random_pseudo66   bool operator()(RawAddress* bd_addr, tBLE_ADDR_TYPE* p_addr_type, bool refresh) {
67     return body(bd_addr, p_addr_type, refresh);
68   }
69 };
70 extern struct btm_identity_addr_to_random_pseudo btm_identity_addr_to_random_pseudo;
71 // Name: btm_identity_addr_to_random_pseudo_from_address_with_type
72 // Params:  tBLE_BD_ADDR* address_with_type, bool refresh
73 // Returns: bool
74 struct btm_identity_addr_to_random_pseudo_from_address_with_type {
75   std::function<bool(tBLE_BD_ADDR* address_with_type, bool refresh)> body{
76           [](tBLE_BD_ADDR* /* address_with_type */, bool /* refresh */) { return false; }};
operatorbtm_identity_addr_to_random_pseudo_from_address_with_type77   bool operator()(tBLE_BD_ADDR* address_with_type, bool refresh) {
78     return body(address_with_type, refresh);
79   }
80 };
81 extern struct btm_identity_addr_to_random_pseudo_from_address_with_type
82         btm_identity_addr_to_random_pseudo_from_address_with_type;
83 // Name: btm_random_pseudo_to_identity_addr
84 // Params: RawAddress* random_pseudo, uint8_t* p_identity_addr_type
85 // Returns: bool
86 struct btm_random_pseudo_to_identity_addr {
87   std::function<bool(RawAddress* random_pseudo, tBLE_ADDR_TYPE* p_identity_addr_type)> body{
88           [](RawAddress* /* random_pseudo */, tBLE_ADDR_TYPE* /* p_identity_addr_type */) {
89             return false;
90           }};
operatorbtm_random_pseudo_to_identity_addr91   bool operator()(RawAddress* random_pseudo, tBLE_ADDR_TYPE* p_identity_addr_type) {
92     return body(random_pseudo, p_identity_addr_type);
93   }
94 };
95 extern struct btm_random_pseudo_to_identity_addr btm_random_pseudo_to_identity_addr;
96 // Name: btm_ble_refresh_peer_resolvable_private_addr
97 // Params:  const RawAddress& pseudo_bda, const RawAddress& rpa,
98 // tBLE_RAND_ADDR_TYPE rra_type Returns: void
99 struct btm_ble_refresh_peer_resolvable_private_addr {
100   std::function<void(const RawAddress& pseudo_bda, const RawAddress& rpa,
101                      tBLE_RAND_ADDR_TYPE rra_type)>
102           body{[](const RawAddress& /* pseudo_bda */, const RawAddress& /* rpa */,
103                   tBLE_RAND_ADDR_TYPE /* rra_type */) {}};
operatorbtm_ble_refresh_peer_resolvable_private_addr104   void operator()(const RawAddress& pseudo_bda, const RawAddress& rpa,
105                   tBLE_RAND_ADDR_TYPE rra_type) {
106     body(pseudo_bda, rpa, rra_type);
107   }
108 };
109 extern struct btm_ble_refresh_peer_resolvable_private_addr
110         btm_ble_refresh_peer_resolvable_private_addr;
111 
112 }  // namespace stack_btm_ble_addr
113 }  // namespace mock
114 }  // namespace test
115 
116 // END mockcify generation
117