A small memory footprint AMQP implimentation
Dependents: iothub_client_sample_amqp remote_monitoring simplesample_amqp
azure_uamqp_c/sasl_frame_codec.h
- Committer:
- AzureIoTClient
- Date:
- 2018-10-04
- Revision:
- 47:365a93fdb5bb
- Parent:
- 43:4c1e4e94cdd3
File content as of revision 47:365a93fdb5bb:
// Copyright (c) Microsoft. All rights reserved. // Licensed under the MIT license. See LICENSE file in the project root for full license information. #ifndef SASL_FRAME_CODEC_H #define SASL_FRAME_CODEC_H #ifdef __cplusplus extern "C" { #include <cstdint> #include <cstddef> #else #include <stdint.h> #include <stddef.h> #endif /* __cplusplus */ #include "azure_uamqp_c/frame_codec.h" #include "azure_c_shared_utility/umock_c_prod.h" #define SASL_MECHANISMS (uint64_t)0x40 #define SASL_INIT (uint64_t)0x41 #define SASL_CHALLENGE (uint64_t)0x42 #define SASL_RESPONSE (uint64_t)0x43 #define SASL_OUTCOME (uint64_t)0x44 typedef struct SASL_FRAME_CODEC_INSTANCE_TAG* SASL_FRAME_CODEC_HANDLE; typedef void(*ON_SASL_FRAME_RECEIVED)(void* context, AMQP_VALUE sasl_frame_value); typedef void(*ON_SASL_FRAME_CODEC_ERROR)(void* context); MOCKABLE_FUNCTION(, SASL_FRAME_CODEC_HANDLE, sasl_frame_codec_create, FRAME_CODEC_HANDLE, frame_codec, ON_SASL_FRAME_RECEIVED, on_sasl_frame_received, ON_SASL_FRAME_CODEC_ERROR, on_sasl_frame_codec_error, void*, callback_context); MOCKABLE_FUNCTION(, void, sasl_frame_codec_destroy, SASL_FRAME_CODEC_HANDLE, sasl_frame_codec); MOCKABLE_FUNCTION(, int, sasl_frame_codec_encode_frame, SASL_FRAME_CODEC_HANDLE, sasl_frame_codec, AMQP_VALUE, sasl_frame_value, ON_BYTES_ENCODED, on_bytes_encoded, void*, callback_context); #ifdef __cplusplus } #endif /* __cplusplus */ #endif /* SASL_FRAME_CODEC_H */