Debian Codegraph @

src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/tests/real_test_files/real_map.h

raw
1 // Copyright (c) Microsoft. All rights reserved.
2 // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
4 #ifndef REAL_MAP_H
5 #define REAL_MAP_H
6
7 #define REGISTER_MAP_GLOBAL_MOCK_HOOK \
8 REGISTER_GLOBAL_MOCK_HOOK(Map_Create, real_Map_Create); \
9 REGISTER_GLOBAL_MOCK_HOOK(Map_Destroy, real_Map_Destroy); \
10 REGISTER_GLOBAL_MOCK_HOOK(Map_Clone, real_Map_Clone); \
11 REGISTER_GLOBAL_MOCK_HOOK(Map_Add, real_Map_Add); \
12 REGISTER_GLOBAL_MOCK_HOOK(Map_AddOrUpdate, real_Map_AddOrUpdate); \
13 REGISTER_GLOBAL_MOCK_HOOK(Map_Delete, real_Map_Delete); \
14 REGISTER_GLOBAL_MOCK_HOOK(Map_ContainsKey, real_Map_ContainsKey); \
15 REGISTER_GLOBAL_MOCK_HOOK(Map_ContainsValue, real_Map_ContainsValue); \
16 REGISTER_GLOBAL_MOCK_HOOK(Map_GetValueFromKey, real_Map_GetValueFromKey); \
17 REGISTER_GLOBAL_MOCK_HOOK(Map_GetInternals, real_Map_GetInternals); \
18 REGISTER_GLOBAL_MOCK_HOOK(Map_ToJSON, real_Map_ToJSON);
19
20 #ifdef __cplusplus
21 #include <cstddef>
22 extern "C"
23 {
24 #else
25 #include <stddef.h>
26 #endif
27 extern MAP_HANDLE real_Map_Create(MAP_FILTER_CALLBACK mapFilterFunc);
28 extern void real_Map_Destroy(MAP_HANDLE handle);
29 extern MAP_HANDLE real_Map_Clone(MAP_HANDLE handle);
30 extern MAP_RESULT real_Map_Add(MAP_HANDLE handle, const char* key, const char* value);
31 extern MAP_RESULT real_Map_AddOrUpdate(MAP_HANDLE handle, const char* key, const char* value);
32 extern MAP_RESULT real_Map_Delete(MAP_HANDLE handle, const char* key);
33 extern MAP_RESULT real_Map_ContainsKey(MAP_HANDLE handle, const char* key, bool* keyExists);
34 extern MAP_RESULT real_Map_ContainsValue(MAP_HANDLE handle, const char* value, bool* valueExists);
35 extern const char* real_Map_GetValueFromKey(MAP_HANDLE handle, const char* key);
36 extern MAP_RESULT real_Map_GetInternals(MAP_HANDLE handle, const char*const** keys, const char*const** values, size_t* count);
37 extern STRING_HANDLE real_Map_ToJSON(MAP_HANDLE handle);
38 #ifdef __cplusplus
39 }
40 #endif
41
42 #endif // !REAL_MAP_H