|
libcoap 4.3.5
|
Strings to be used in the CoAP library. More...
#include <string.h>
Include dependency graph for coap_str.h:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Data Structures | |
| struct | coap_string_t |
| CoAP string data definition. More... | |
| struct | coap_str_const_t |
| CoAP string data definition with const data. More... | |
| struct | coap_binary_t |
| CoAP binary data definition. More... | |
| struct | coap_bin_const_t |
| CoAP binary data definition with const data. More... | |
| union | coap_const_char_ptr_t |
| CoAP union for handling signed / unsigned chars. More... | |
Macros | |
| #define | COAP_SET_STR(st, l, v) { (st)->length = (l), (st)->s = (v); } |
| #define | COAP_MAX_STR_CONST_FUNC 2 |
| #define | coap_string_equal(string1, string2) |
| Compares the two strings for equality. | |
| #define | coap_binary_equal(binary1, binary2) |
| Compares the two binary data for equality. | |
Typedefs | |
| typedef struct coap_string_t | coap_string_t |
| CoAP string data definition. | |
| typedef struct coap_str_const_t | coap_str_const_t |
| CoAP string data definition with const data. | |
| typedef struct coap_binary_t | coap_binary_t |
| CoAP binary data definition. | |
| typedef struct coap_bin_const_t | coap_bin_const_t |
| CoAP binary data definition with const data. | |
Functions | |
| coap_string_t * | coap_new_string (size_t size) |
| Returns a new string object with at least size+1 bytes storage allocated. | |
| void | coap_delete_string (coap_string_t *string) |
| Deletes the given string and releases any memory allocated. | |
| coap_str_const_t * | coap_new_str_const (const uint8_t *data, size_t size) |
| Returns a new const string object with at least size+1 bytes storage allocated, and the provided data copied into the string object. | |
| void | coap_delete_str_const (coap_str_const_t *string) |
| Deletes the given const string and releases any memory allocated. | |
| coap_binary_t * | coap_new_binary (size_t size) |
| Returns a new binary object with at least size bytes storage allocated. | |
| void | coap_delete_binary (coap_binary_t *binary) |
| Deletes the given coap_binary_t object and releases any memory allocated. | |
| coap_binary_t * | coap_resize_binary (coap_binary_t *binary, size_t new_size) |
| Resizes the given coap_binary_t object. | |
| coap_bin_const_t * | coap_new_bin_const (const uint8_t *data, size_t size) |
| Take the specified byte array (text) and create a coap_bin_const_t * Returns a new const binary object with at least size bytes storage allocated, and the provided data copied into the binary object. | |
| void | coap_delete_bin_const (coap_bin_const_t *binary) |
| Deletes the given const binary data and releases any memory allocated. | |
| coap_str_const_t * | coap_make_str_const (const char *string) |
| Take the specified byte array (text) and create a coap_str_const_t *. | |
Strings to be used in the CoAP library.
Definition in file coap_str.h.