Function coap_handler_implementations::new_dispatcher [−][src]
pub fn new_dispatcher() -> NeverFound
Start building a tree of sub-resources
While technically this just returns a handler that returns 4.04 unconditionally, it also implemnts HandlerBuilder, and thus can be used like this:
use coap_handler::implementations::*; let handler = new_dispatcher() .at(&["dev", "name"], TypedStaticResponse::from("Demo program")) .at(&["dev", "version"], TypedStaticResponse::from("0.8.15")) ;