var searchIndex = {}; searchIndex["coap"] = {"doc":"Implementation of the [CoAP Protocol][spec].","items":[[0,"message","coap","",null,null],[0,"header","coap::message","",null,null],[3,"HeaderRaw","coap::message::header","",null,null],[3,"Header","","",null,null],[12,"code","","",0,null],[4,"MessageClass","","",null,null],[13,"Empty","","",1,null],[13,"RequestType","","",1,null],[13,"ResponseType","","",1,null],[13,"Reserved","","",1,null],[4,"Requests","","",null,null],[13,"Get","","",2,null],[13,"Post","","",2,null],[13,"Put","","",2,null],[13,"Delete","","",2,null],[4,"Responses","","",null,null],[13,"Created","","",3,null],[13,"Deleted","","",3,null],[13,"Valid","","",3,null],[13,"Changed","","",3,null],[13,"Content","","",3,null],[13,"BadRequest","","",3,null],[13,"Unauthorized","","",3,null],[13,"BadOption","","",3,null],[13,"Forbidden","","",3,null],[13,"NotFound","","",3,null],[13,"MethodNotAllowed","","",3,null],[13,"NotAcceptable","","",3,null],[13,"PreconditionFailed","","",3,null],[13,"RequestEntityTooLarge","","",3,null],[13,"UnsupportedContentFormat","","",3,null],[13,"InternalServerError","","",3,null],[13,"NotImplemented","","",3,null],[13,"BadGateway","","",3,null],[13,"ServiceUnavailable","","",3,null],[13,"GatewayTimeout","","",3,null],[13,"ProxyingNotSupported","","",3,null],[4,"MessageType","","",null,null],[13,"Confirmable","","",4,null],[13,"NonConfirmable","","",4,null],[13,"Acknowledgement","","",4,null],[13,"Reset","","",4,null],[13,"Invalid","","",4,null],[5,"class_to_code","","",null,{"inputs":[{"name":"messageclass"}],"output":{"name":"u8"}}],[5,"code_to_class","","",null,{"inputs":[{"name":"u8"}],"output":{"name":"messageclass"}}],[5,"code_to_str","","",null,{"inputs":[{"name":"u8"}],"output":{"name":"string"}}],[5,"class_to_str","","",null,{"inputs":[{"name":"messageclass"}],"output":{"name":"string"}}],[11,"decode","","",5,{"inputs":[{"name":"__d"}],"output":{"name":"result"}}],[11,"encode","","",5,null],[11,"fmt","","",5,null],[11,"default","","",5,{"inputs":[],"output":{"name":"headerraw"}}],[11,"fmt","","",0,null],[11,"eq","","",1,null],[11,"ne","","",1,null],[11,"fmt","","",1,null],[11,"eq","","",2,null],[11,"fmt","","",2,null],[11,"eq","","",3,null],[11,"fmt","","",3,null],[11,"fmt","","",4,null],[11,"eq","","",4,null],[11,"new","","",0,{"inputs":[],"output":{"name":"header"}}],[11,"from_raw","","",0,{"inputs":[{"name":"headerraw"}],"output":{"name":"header"}}],[11,"to_raw","","",0,null],[11,"set_version","","",0,null],[11,"get_version","","",0,null],[11,"set_type","","",0,null],[11,"get_type","","",0,null],[11,"set_token_length","","",0,null],[11,"get_token_length","","",0,null],[11,"set_code","","",0,null],[11,"get_code","","",0,null],[11,"set_message_id","","",0,null],[11,"get_message_id","","",0,null],[0,"request","coap::message","",null,null],[3,"CoAPRequest","coap::message::request","",null,null],[12,"message","","",6,null],[12,"response","","",6,null],[12,"source","","",6,null],[11,"fmt","","",6,null],[11,"new","","",6,{"inputs":[],"output":{"name":"coaprequest"}}],[11,"from_packet","","",6,{"inputs":[{"name":"packet"},{"name":"socketaddr"}],"output":{"name":"coaprequest"}}],[11,"get_message","","",6,null],[11,"get_mut_message","","",6,null],[11,"get_header","","",6,null],[11,"get_mut_header","","",6,null],[0,"response","coap::message","",null,null],[3,"CoAPResponse","coap::message::response","",null,null],[12,"message","","",7,null],[11,"fmt","","",7,null],[11,"new","","",7,{"inputs":[{"name":"packet"}],"output":{"name":"option"}}],[11,"get_message","","",7,null],[11,"get_mut_message","","",7,null],[11,"get_header","","",7,null],[11,"get_mut_header","","",7,null],[0,"packet","coap::message","",null,null],[3,"Packet","coap::message::packet","",null,null],[12,"header","","",8,null],[12,"payload","","",8,null],[4,"CoAPOption","","",null,null],[13,"IfMatch","","",9,null],[13,"UriHost","","",9,null],[13,"ETag","","",9,null],[13,"IfNoneMatch","","",9,null],[13,"Observe","","",9,null],[13,"UriPort","","",9,null],[13,"LocationPath","","",9,null],[13,"UriPath","","",9,null],[13,"ContentFormat","","",9,null],[13,"MaxAge","","",9,null],[13,"UriQuery","","",9,null],[13,"Accept","","",9,null],[13,"LocationQuery","","",9,null],[13,"Block2","","",9,null],[13,"Block1","","",9,null],[13,"ProxyUri","","",9,null],[13,"ProxyScheme","","",9,null],[13,"Size1","","",9,null],[4,"PackageError","","",null,null],[13,"InvalidHeader","","",10,null],[13,"InvalidPacketLength","","",10,null],[4,"ParseError","","",null,null],[13,"InvalidHeader","","",11,null],[13,"InvalidTokenLength","","",11,null],[13,"InvalidOptionDelta","","",11,null],[13,"InvalidOptionLength","","",11,null],[11,"fmt","","",9,null],[11,"eq","","",9,null],[11,"fmt","","",10,null],[11,"fmt","","",11,null],[11,"fmt","","",8,null],[11,"new","","",8,{"inputs":[],"output":{"name":"packet"}}],[11,"set_token","","",8,null],[11,"get_token","","",8,null],[11,"set_option","","",8,null],[11,"set_payload","","",8,null],[11,"add_option","","",8,null],[11,"get_option","","",8,null],[11,"from_bytes","","Decodes a byte slice and construct the equivalent Packet.",8,null],[11,"to_bytes","","Returns a vector of bytes representing the Packet.",8,null],[8,"IsMessage","coap::message","",null,null],[10,"get_message","","",12,null],[10,"get_mut_message","","",12,null],[10,"get_header","","",12,null],[10,"get_mut_header","","",12,null],[11,"set_token","","",12,null],[11,"get_token","","",12,null],[11,"set_option","","",12,null],[11,"set_payload","","",12,null],[11,"add_option","","",12,null],[11,"get_option","","",12,null],[11,"get_message_id","","",12,null],[11,"set_message_id","","",12,null],[11,"set_version","","",12,null],[11,"get_version","","",12,null],[11,"set_type","","",12,null],[11,"get_type","","",12,null],[11,"get_code","","",12,null],[11,"set_code","","",12,null],[0,"client","coap","",null,null],[3,"CoAPClient","coap::client","",null,null],[11,"new","","Create a CoAP client with the peer address.",13,{"inputs":[{"name":"a"}],"output":{"name":"result"}}],[11,"request_with_timeout","","Execute a request with the coap url and a specific timeout. Default timeout is 5s.",13,{"inputs":[{"name":"str"},{"name":"option"}],"output":{"name":"result"}}],[11,"request","","Execute a request with the coap url.",13,{"inputs":[{"name":"str"}],"output":{"name":"result"}}],[11,"send","","Execute a request.",13,null],[11,"receive","","Receive a response.",13,null],[11,"set_receive_timeout","","Set the receive timeout.",13,null],[0,"server","coap","",null,null],[3,"CoAPServer","coap::server","",null,null],[4,"CoAPServerError","","",null,null],[13,"NetworkError","","",14,null],[13,"EventLoopError","","",14,null],[13,"AnotherHandlerIsRunning","","",14,null],[8,"CoAPHandler","","",null,null],[10,"handle","","",15,null],[11,"fmt","","",14,null],[11,"new","","Creates a CoAP server listening on the given address.",16,{"inputs":[{"name":"a"}],"output":{"name":"result"}}],[11,"handle","","Starts handling requests with the handler",16,null],[11,"stop","","Stop the server.",16,null],[11,"drop","","",16,null]],"paths":[[3,"Header"],[4,"MessageClass"],[4,"Requests"],[4,"Responses"],[4,"MessageType"],[3,"HeaderRaw"],[3,"CoAPRequest"],[3,"CoAPResponse"],[3,"Packet"],[4,"CoAPOption"],[4,"PackageError"],[4,"ParseError"],[8,"IsMessage"],[3,"CoAPClient"],[4,"CoAPServerError"],[8,"CoAPHandler"],[3,"CoAPServer"]]}; initSearch(searchIndex);