fromOptions
fun fromOptions(scheme: CoapScheme, destinationHost: String, destinationPort: Int, options: OptionSet): CoapUri(source)
Rebuilds a URI from request options (RFC 7252 §6.5), as a server or proxy sees it: Uri-Host and Uri-Port where present, else destinationHost and destinationPort. For options the application built; the options of a received request are a peer's input and go through fromOptionsOrNull.
Throws
when the host is empty or the port is outside 1..65535, such as an empty Uri-Port option, which is the value 0 (RFC 7252 §3.2).