prf::net::CoapService class final

lwIP raw-UDP backed CoAP service.

The service owns one UDP PCB and forwards each inbound datagram to prf::coap::Server::handle_datagram_into().

Base classes

class ICoapService
CoAP UDP service abstraction.

Constructors, destructors, conversion operators

CoapService(const prf::coap::Server& server, size_t max_datagram_bytes = prf::coap::kCoapMaxDatagramBytes) explicit
Creates service bound to one endpoint router instance.

Public functions

auto is_running() const -> bool override
Returns true when listener PCB is active.
auto start(uint16_t listen_port) -> bool override
Opens UDP listener and starts datagram dispatching.
void stop() override
Stops listener and releases UDP resources.