Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: sht15_remote_monitoring f767zi_mqtt remote_monitoring simplesample_amqp ... more
dataserializer.h
00001 // Copyright (c) Microsoft. All rights reserved. 00002 // Licensed under the MIT license. See LICENSE file in the project root for full license information. 00003 00004 #ifndef DATASERIALIZER_H 00005 #define DATASERIALIZER_H 00006 00007 #include "azure_c_shared_utility/macro_utils.h" 00008 #include "multitree.h" 00009 #include "azure_c_shared_utility/buffer_.h" 00010 00011 #ifdef __cplusplus 00012 #include <cstddef> 00013 extern "C" 00014 { 00015 #else 00016 #include <stddef.h> 00017 #endif 00018 00019 /*Codes_SRS_DATA_SERIALIZER_07_001: [DataSerializer will have the following interface]*/ 00020 #define DATA_SERIALIZER_RESULT_VALUES \ 00021 DATA_SERIALIZER_INVALID_ARG, \ 00022 DATA_SERIALIZER_ERROR \ 00023 00024 DEFINE_ENUM(DATA_SERIALIZER_RESULT, DATA_SERIALIZER_RESULT_VALUES); 00025 00026 #define DATA_SERIALIZER_MULTITREE_TYPE_VALUES \ 00027 DATA_SERIALIZER_TYPE_CHAR_PTR, \ 00028 DATA_SERIALIZER_TYPE_AGENT_DATA \ 00029 00030 DEFINE_ENUM(DATA_SERIALIZER_MULTITREE_TYPE, DATA_SERIALIZER_MULTITREE_TYPE_VALUES); 00031 00032 typedef BUFFER_HANDLE (*DATA_SERIALIZER_ENCODE_FUNC)(MULTITREE_HANDLE multiTreeHandle, DATA_SERIALIZER_MULTITREE_TYPE dataType); 00033 typedef MULTITREE_HANDLE (*DATA_SERIALIZER_DECODE_FUNC)(BUFFER_HANDLE decodeData); 00034 00035 extern BUFFER_HANDLE DataSerializer_Encode(MULTITREE_HANDLE multiTreeHandle, DATA_SERIALIZER_MULTITREE_TYPE dataType, DATA_SERIALIZER_ENCODE_FUNC encodeFunc); 00036 extern MULTITREE_HANDLE DataSerializer_Decode(BUFFER_HANDLE data, DATA_SERIALIZER_DECODE_FUNC decodeFunc); 00037 00038 #ifdef __cplusplus 00039 } 00040 #endif 00041 00042 #endif // DATASERIALIZER_H
Generated on Tue Jul 12 2022 19:56:37 by
1.7.2