riot_coap_handler_demos::stdio

Function read

Source
pub fn read() -> impl Handler
Available on crate feature riot-wrappers only.
Expand description

A resource that, when POSTed to, reads up to whichever internally decided buffer length from stdin

ยงWarning

This is not only an unusual implementation of Handler (as is write(); here, lack of the retranmission buffering associated with deduplication leads to lost input), but also a bad implementation of Handler as it blocks arbitrarily (making it even more likely that retransmissions occur).