OptionSet

The options of a message, kept in ascending number order as they are encoded. Repeated options keep their relative order, which matters for Uri-Path and the like (RFC 7252 §5.4.5).

Typed properties decode the options this library knows; first and all give raw access to any option, including ones registered by the application.

Types

Link copied to clipboard
class Builder

Collects options; build sorts them by number, keeping the insertion order of repeated ones. Typed setters replace earlier values of a non-repeatable option.

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
val accept: Int?
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Max-Age in seconds; RFC 7252 §5.10.5 defaults it to 60 when absent.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Uri-Path joined with "/" and a leading "/", or "/" when there is none.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

The Q-Block1 option (RFC 9177 §4.2), which a message carries at most once.

Link copied to clipboard

The first Q-Block2 option (RFC 9177 §4.2); a request for missing blocks repeats it, see qBlock2List.

Link copied to clipboard

Every Q-Block2 option in order: one per block a request for missing blocks asks for (RFC 9177 §4.4).

Link copied to clipboard
Link copied to clipboard
val size: Int
Link copied to clipboard
val size1: Long?
Link copied to clipboard
val size2: Long?
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val uriPort: Int?
Link copied to clipboard

Functions

Link copied to clipboard
fun all(number: Int): List<CoapOption>
Link copied to clipboard
operator fun contains(number: Int): Boolean
Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
fun first(number: Int): CoapOption?
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
Link copied to clipboard
open operator override fun iterator(): Iterator<CoapOption>
Link copied to clipboard
Link copied to clipboard
open override fun toString(): String