MQTTProperties.h
Go to the documentation of this file.
1 /*******************************************************************************
2  * Copyright (c) 2017, 2020 IBM Corp. and others
3  *
4  * All rights reserved. This program and the accompanying materials
5  * are made available under the terms of the Eclipse Public License v2.0
6  * and Eclipse Distribution License v1.0 which accompany this distribution.
7  *
8  * The Eclipse Public License is available at
9  * https://www.eclipse.org/legal/epl-2.0/
10  * and the Eclipse Distribution License is available at
11  * http://www.eclipse.org/org/documents/edl-v10.php.
12  *
13  * Contributors:
14  * Ian Craggs - initial API and implementation and/or initial documentation
15  *******************************************************************************/
16 
17 #if !defined(MQTTPROPERTIES_H)
18 #define MQTTPROPERTIES_H
19 
20 #include "MQTTExportDeclarations.h"
21 
22 #define MQTT_INVALID_PROPERTY_ID -2
23 
53 };
54 
62 
72 };
73 
80 
84 typedef struct
85 {
86  int len;
87  char* data;
89 
90 
94 typedef struct
95 {
96  enum MQTTPropertyCodes identifier;
98  union {
99  unsigned char byte;
100  unsigned short integer2;
101  unsigned int integer4;
102  struct {
105  };
106  } value;
107 } MQTTProperty;
108 
112 typedef struct MQTTProperties
113 {
114  int count;
115  int max_count;
116  int length;
119 
120 #define MQTTProperties_initializer {0, 0, 0, NULL}
121 
128 
136 
143 int MQTTProperties_write(char** pptr, const MQTTProperties* properties);
144 
152 int MQTTProperties_read(MQTTProperties* properties, char** pptr, char* enddata);
153 
159 
166 
174 
183 
191 
201 
209 
218 
219 #endif /* MQTTPROPERTIES_H */
unsigned char byte
LIBMQTT_API void MQTTProperties_free(MQTTProperties *properties)
LIBMQTT_API int MQTTProperties_getNumericValue(MQTTProperties *props, enum MQTTPropertyCodes propid)
enum MQTTPropertyCodes value
struct MQTTProperties MQTTProperties
MQTTProperties props
Definition: paho_c_pub.c:54
LIBMQTT_API MQTTProperty * MQTTProperties_getProperty(MQTTProperties *props, enum MQTTPropertyCodes propid)
MQTTLenString value
MQTTLenString data
#define LIBMQTT_API
LIBMQTT_API int MQTTProperties_add(MQTTProperties *props, const MQTTProperty *prop)
LIBMQTT_API MQTTProperty * MQTTProperties_getPropertyAt(MQTTProperties *props, enum MQTTPropertyCodes propid, int index)
LIBMQTT_API int MQTTProperty_getType(enum MQTTPropertyCodes value)
LIBMQTT_API int MQTTProperties_hasProperty(MQTTProperties *props, enum MQTTPropertyCodes propid)
LIBMQTT_API int MQTTProperties_propertyCount(MQTTProperties *props, enum MQTTPropertyCodes propid)
int MQTTProperties_read(MQTTProperties *properties, char **pptr, char *enddata)
LIBMQTT_API const char * MQTTPropertyName(enum MQTTPropertyCodes value)
unsigned int integer4
MQTTProperty * array
MQTTPropertyTypes
int MQTTProperties_write(char **pptr, const MQTTProperties *properties)
LIBMQTT_API MQTTProperties MQTTProperties_copy(const MQTTProperties *props)
unsigned short integer2
LIBMQTT_API int MQTTProperties_getNumericValueAt(MQTTProperties *props, enum MQTTPropertyCodes propid, int index)
MQTTPropertyCodes
int MQTTProperties_len(MQTTProperties *props)


plotjuggler
Author(s): Davide Faconti
autogenerated on Sun Dec 6 2020 03:48:09