[][src]Enum libtelnet_rs::events::TelnetEvents

pub enum TelnetEvents {
    IAC(TelnetIAC),
    Negotiation(TelnetNegotiation),
    Subnegotiation(TelnetSubnegotiation),
    DataReceive(Vec<u8>),
    DataSend(Vec<u8>),
    DecompressImmediate(Vec<u8>),
}

An enum representing various telnet events.

Variants

An IAC command sequence.

Negotiation(TelnetNegotiation)

An IAC negotiation sequence.

Subnegotiation(TelnetSubnegotiation)

An IAC subnegotiation sequence.

DataReceive(Vec<u8>)

Regular data received from the remote end.

DataSend(Vec<u8>)

Any data to be sent to the remote end.

DecompressImmediate(Vec<u8>)

MCCP2/3 compatibility. MUST DECOMPRESS THIS DATA BEFORE PARSING

Implementations

impl TelnetEvents[src]

pub fn build_send(buffer: Vec<u8>) -> Self[src]

Helper method to generate a TelnetEvents::DataSend.

pub fn build_receive(buffer: Vec<u8>) -> Self[src]

Helper method to generate a TelnetEvents::DataReceive.

pub fn build_iac(command: u8) -> TelnetEvents[src]

Helper method to generate a TelnetEvents::IAC.

pub fn build_negotiation(command: u8, option: u8) -> Self[src]

Helper method to generate a TelnetEvents::Negotiation.

pub fn build_subnegotiation(option: u8, buffer: Vec<u8>) -> Self[src]

Helper method to generate a TelnetEvents::Subnegotiation.

Trait Implementations

impl Clone for TelnetEvents[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.