TelnetSession

Ordered, single-consumer input and concurrent suspend output operations.

Properties

Link copied to clipboard
abstract val state: StateFlow<TelnetSnapshot>

Functions

Link copied to clipboard
abstract suspend fun carriageReturn(): TelnetOutcome<Unit>
Link copied to clipboard
abstract suspend fun close(): TelnetOutcome<Unit>
Link copied to clipboard
abstract suspend fun flush(): TelnetOutcome<Unit>
Link copied to clipboard

Local socket endpoint captured when the session opens.

Link copied to clipboard
abstract suspend fun receive(): TelnetOutcome<TelnetInput?>
Link copied to clipboard
abstract suspend fun requestOption(option: TelnetOption, direction: TelnetDirection, enable: Boolean): TelnetOutcome<Unit>
Link copied to clipboard
abstract suspend fun resize(columns: Int, rows: Int): TelnetOutcome<Unit>
Link copied to clipboard
abstract suspend fun sendCommand(command: TelnetCommand): TelnetOutcome<Unit>
Link copied to clipboard
abstract suspend fun write(data: ByteArray, offset: Int = 0, length: Int = data.size - offset): TelnetOutcome<Unit>