coap_client_request.h
error_t coapClientDeleteOption(CoapMessage *message, uint16_t optionNum, uint_t optionIndex)
Remove an option from the CoAP message.
Definition: coap_client_request.c:808
error_t coapClientGetLocationQuery(const CoapMessage *message, char_t *queryString, size_t maxLen)
Get Location-Query option.
Definition: coap_client_request.c:645
void coapClientDeleteRequest(CoapClientRequest *request)
Release the resources associated with a CoAP request.
Definition: coap_client_request.c:349
error_t coapClientSetPayload(CoapMessage *message, const void *payload, size_t payloadLen)
Set message payload.
Definition: coap_client_request.c:828
error_t coapClientReadPayload(CoapMessage *message, void *data, size_t size, size_t *length)
Read payload data.
Definition: coap_client_request.c:893
error_t coapClientSetUriQuery(CoapMessage *message, const char_t *queryString)
Set Uri-Query option.
Definition: coap_client_request.c:583
error_t coapClientSetUintOption(CoapMessage *message, uint16_t optionNum, uint_t optionIndex, uint32_t optionValue)
Add a uint option to the CoAP message.
Definition: coap_client_request.c:721
error_t coapClientWritePayload(CoapMessage *message, const void *data, size_t length)
Write payload data.
Definition: coap_client_request.c:872
error_t coapClientGetType(const CoapMessage *message, CoapMessageType *type)
Get message type.
Definition: coap_client_request.c:472
error_t coapClientGetResponseCode(const CoapMessage *message, CoapCode *code)
Get response code.
Definition: coap_client_request.c:526
error_t coapClientSetUriPath(CoapMessage *message, const char_t *path)
Set Uri-Path option.
Definition: coap_client_request.c:544
error_t coapClientSetStringOption(CoapMessage *message, uint16_t optionNum, uint_t optionIndex, const char_t *optionValue)
Add a string option to the CoAP message.
Definition: coap_client_request.c:694
error_t coapClientSetMethodCode(CoapMessage *message, CoapCode code)
Set request method.
Definition: coap_client_request.c:490
error_t coapClientCancelRequest(CoapClientRequest *request)
Cancel an outstanding CoAP request.
Definition: coap_client_request.c:275
error_t coapClientGetLocationPath(const CoapMessage *message, char_t *path, size_t maxLen)
Get Location-Path option.
Definition: coap_client_request.c:624
error_t coapClientGetMethodCode(const CoapMessage *message, CoapCode *code)
Get request method.
Definition: coap_client_request.c:508
error_t coapClientSetRequestTimeout(CoapClientRequest *request, systime_t timeout)
Set request timeout.
Definition: coap_client_request.c:130
CoAP client.
CoapMessage * coapClientGetRequestMessage(CoapClientRequest *request)
Get request message.
Definition: coap_client_request.c:370
CoapMessage * coapClientGetResponseMessage(CoapClientRequest *request)
Get response message.
Definition: coap_client_request.c:414
systime_t retransmitStartTime
Time at which the last message was sent.
Definition: coap_client_request.h:96
CoapClientRequest * coapClientCreateRequest(CoapClientContext *context)
Initialize a new CoAP request.
Definition: coap_client_request.c:53
CoapRequestCallback callback
Callback function to invoke when the request completes.
Definition: coap_client_request.h:107
error_t coapClientGetUintOption(const CoapMessage *message, uint16_t optionNum, uint_t optionIndex, uint32_t *optionValue)
Read an uint option from the CoAP message.
Definition: coap_client_request.c:788
error_t coapClientGetUriPath(const CoapMessage *message, char_t *path, size_t maxLen)
Get Uri-Path option.
Definition: coap_client_request.c:563
error_t coapClientSendRequest(CoapClientRequest *request, CoapRequestCallback callback, void *param)
Send a CoAP request.
Definition: coap_client_request.c:157
error_t coapClientSetType(CoapMessage *message, CoapMessageType type)
Set message type.
Definition: coap_client_request.c:454
error_t coapClientGetOpaqueOption(const CoapMessage *message, uint16_t optionNum, uint_t optionIndex, const uint8_t **optionValue, size_t *optionLen)
Read an opaque option from the CoAP message.
Definition: coap_client_request.c:743
error_t coapClientGetPayload(const CoapMessage *message, const uint8_t **payload, size_t *payloadLen)
Get message payload.
Definition: coap_client_request.c:852
error_t(* CoapRequestCallback)(CoapClientContext *context, CoapClientRequest *request, CoapRequestStatus status, void *param)
Request completed callback.
Definition: coap_client_request.h:82
error_t coapClientGetUriQuery(const CoapMessage *message, char_t *queryString, size_t maxLen)
Get Uri-Query option.
Definition: coap_client_request.c:603
TCP/IP stack core.
uint32_t observeSeqNum
Sequence number for reordering detection.
Definition: coap_client_request.h:100
error_t coapClientGetStringOption(const CoapMessage *message, uint16_t optionNum, uint_t optionIndex, const char_t **optionValue, size_t *optionLen)
Read a string option from the CoAP message.
Definition: coap_client_request.c:766
Formatting and parsing of CoAP options.
error_t coapClientSetOpaqueOption(CoapMessage *message, uint16_t optionNum, uint_t optionIndex, const uint8_t *optionValue, size_t optionLen)
Add an opaque option to the CoAP message.
Definition: coap_client_request.c:668