|
libcoap 4.3.5
|
CoAP PDU internal information. More...
Go to the source code of this file.
Data Structures | |
| struct | coap_pdu_t |
| structure for CoAP PDUs More... | |
Macros | |
| #define | COAP_DEFAULT_VERSION 1 |
| #define | COAP_MESSAGE_SIZE_OFFSET_TCP8 13 |
| #define | COAP_MESSAGE_SIZE_OFFSET_TCP16 269 |
| #define | COAP_MESSAGE_SIZE_OFFSET_TCP32 65805 |
| #define | COAP_MAX_MESSAGE_SIZE_TCP0 (COAP_MESSAGE_SIZE_OFFSET_TCP8-1) |
| #define | COAP_MAX_MESSAGE_SIZE_TCP8 (COAP_MESSAGE_SIZE_OFFSET_TCP16-1) |
| #define | COAP_MAX_MESSAGE_SIZE_TCP16 (COAP_MESSAGE_SIZE_OFFSET_TCP32-1) |
| #define | COAP_MAX_MESSAGE_SIZE_TCP32 (COAP_MESSAGE_SIZE_OFFSET_TCP32+0xFFFFFFFF) |
| #define | COAP_TOKEN_EXT_1B_TKL 13 |
| #define | COAP_TOKEN_EXT_2B_TKL 14 |
| #define | COAP_TOKEN_EXT_1B_BIAS 13 |
| #define | COAP_TOKEN_EXT_2B_BIAS 269 |
| #define | COAP_DROPPED_RESPONSE -2 |
| Indicates that a response is suppressed. | |
| #define | COAP_PDU_DELAYED -3 |
| #define | COAP_PAYLOAD_START 0xFF |
| #define | COAP_PDU_IS_EMPTY(pdu) |
| #define | COAP_PDU_IS_REQUEST(pdu) |
| #define | COAP_PDU_IS_RESPONSE(pdu) |
| #define | COAP_PDU_IS_SIGNALING(pdu) |
| #define | COAP_PDU_IS_PING(pdu) |
| #define | COAP_PDU_MAX_UDP_HEADER_SIZE 4 |
| #define | COAP_PDU_MAX_TCP_HEADER_SIZE 6 |
Functions | |
| int | coap_pdu_resize (coap_pdu_t *pdu, size_t new_size) |
Dynamically grows the size of pdu to new_size. | |
| int | coap_pdu_check_resize (coap_pdu_t *pdu, size_t new_size) |
Dynamically grows the size of pdu to new_size if needed. | |
| size_t | coap_pdu_parse_header_size (coap_proto_t proto, const uint8_t *data) |
Interprets data to determine the number of bytes in the header. | |
| size_t | coap_pdu_parse_size (coap_proto_t proto, const uint8_t *data, size_t length) |
Parses data to extract the message size. | |
| int | coap_pdu_parse_header (coap_pdu_t *pdu, coap_proto_t proto) |
| Decode the protocol specific header for the specified PDU. | |
| int | coap_pdu_parse_opt (coap_pdu_t *pdu) |
| Verify consistency in the given CoAP PDU structure and locate the data. | |
| void | coap_pdu_clear (coap_pdu_t *pdu, size_t size) |
Clears any contents from pdu and resets used_size, and data pointers. | |
| size_t | coap_add_option_internal (coap_pdu_t *pdu, coap_option_num_t number, size_t len, const uint8_t *data) |
Adds option of given number to pdu that is passed as first parameter. | |
| int | coap_remove_option (coap_pdu_t *pdu, coap_option_num_t number) |
Removes (first) option of given number from the pdu. | |
| size_t | coap_insert_option (coap_pdu_t *pdu, coap_option_num_t number, size_t len, const uint8_t *data) |
Inserts option of given number in the pdu with the appropriate data. | |
| size_t | coap_update_option (coap_pdu_t *pdu, coap_option_num_t number, size_t len, const uint8_t *data) |
Updates existing first option of given number in the pdu with the new data. | |
| size_t | coap_pdu_encode_header (coap_pdu_t *pdu, coap_proto_t proto) |
| Compose the protocol specific header for the specified PDU. | |
| int | coap_update_token (coap_pdu_t *pdu, size_t len, const uint8_t *data) |
Updates token in pdu with length len and data. | |
| int | coap_option_check_repeatable (coap_option_num_t number) |
| Check whether the option is allowed to be repeated or not. | |
| coap_pdu_t * | coap_new_pdu_lkd (coap_pdu_type_t type, coap_pdu_code_t code, coap_session_t *session) |
| Creates a new CoAP PDU. | |
| coap_pdu_t * | coap_pdu_duplicate_lkd (const coap_pdu_t *old_pdu, coap_session_t *session, size_t token_length, const uint8_t *token, coap_opt_filter_t *drop_options) |
| Duplicate an existing PDU. | |
CoAP PDU internal information.
Definition in file coap_pdu_internal.h.