Lines Matching +full:resource +full:- +full:id
5 * SPDX-License-Identifier: Apache-2.0
16 static int piggyback_get(struct coap_resource *resource, in piggyback_get() argument
24 uint16_t id; in piggyback_get() local
32 id = coap_header_get_id(request); in piggyback_get()
36 LOG_INF("type: %u code %u id %u", type, code, id); in piggyback_get()
47 COAP_RESPONSE_CODE_CONTENT, id); in piggyback_get()
63 /* The response that coap-client expects */ in piggyback_get()
65 "Type: %u\nCode: %u\nMID: %u\n", type, code, id); in piggyback_get()
76 r = coap_resource_send(resource, &response, addr, addr_len, NULL); in piggyback_get()
81 static int test_del(struct coap_resource *resource, in test_del() argument
91 uint16_t id; in test_del() local
96 id = coap_header_get_id(request); in test_del()
100 LOG_INF("type: %u code %u id %u", type, code, id); in test_del()
111 COAP_RESPONSE_CODE_DELETED, id); in test_del()
116 r = coap_resource_send(resource, &response, addr, addr_len, NULL); in test_del()
121 static int test_put(struct coap_resource *resource, in test_put() argument
133 uint16_t id; in test_put() local
138 id = coap_header_get_id(request); in test_put()
142 LOG_INF("type: %u code %u id %u", type, code, id); in test_put()
158 COAP_RESPONSE_CODE_CHANGED, id); in test_put()
163 r = coap_resource_send(resource, &response, addr, addr_len, NULL); in test_put()
168 static int test_post(struct coap_resource *resource, in test_post() argument
185 uint16_t id; in test_post() local
190 id = coap_header_get_id(request); in test_post()
194 LOG_INF("type: %u code %u id %u", type, code, id); in test_post()
210 COAP_RESPONSE_CODE_CREATED, id); in test_post()
224 r = coap_resource_send(resource, &response, addr, addr_len, NULL); in test_post()