KNX IoT
KNX IoT Point API stack implementation
|
CoAP Discovery. More...
#include <stddef.h>
Go to the source code of this file.
Functions | |
bool | oc_add_resource_to_wk (const oc_resource_t *resource, oc_request_t *request, size_t device_index, size_t *response_length, int truncate) |
add the resource to the response in application link format More... | |
void | oc_create_discovery_resource (int resource_idx, size_t device) |
create a resource that is discoverable. More... | |
bool | oc_filter_resource (const oc_resource_t *resource, oc_request_t *request, size_t device_index, size_t *response_length, int *skipped, int first_entry, int truncate) |
filter resource if it needs to be included in the response of a link-format response More... | |
CoAP Discovery.
Definition in file oc_discovery.h.
bool oc_add_resource_to_wk | ( | const oc_resource_t * | resource, |
oc_request_t * | request, | ||
size_t | device_index, | ||
size_t * | response_length, | ||
int | truncate | ||
) |
add the resource to the response in application link format
resource | the resource |
request | the request |
device_index | the device index |
response_length | the response length (to be increased) |
truncate | 1 = do urn truncation; remove the urn part of the rt value |
void oc_create_discovery_resource | ( | int | resource_idx, |
size_t | device | ||
) |
create a resource that is discoverable.
resource_idx | the resource index |
device | the device to which the resource belongs |
bool oc_filter_resource | ( | const oc_resource_t * | resource, |
oc_request_t * | request, | ||
size_t | device_index, | ||
size_t * | response_length, | ||
int * | skipped, | ||
int | first_entry, | ||
int | truncate | ||
) |
filter resource if it needs to be included in the response of a link-format response
resource | the resource to be included |
request | the request, with all query parameters |
device_index | the device index on the request is being made |
response_length | the current response length |
skipped | number of entries already skipped |
first_entry | first entry to be included |
truncate | whether to truncate the response payload |