[][src]Struct mosquitto_rs::ConnectionStatus

pub struct ConnectionStatus(pub c_int);

Represents the status of the connection attempt. The embedded status code value depends on the protocol version that was setup for the client. For MQTT v5.0, look at section 3.2.2.2 Connect Reason code: https://docs.oasis-open.org/mqtt/mqtt/v5.0/os/mqtt-v5.0-os.html For MQTT v3.1.1, look at section 3.2.2.3 Connect Return code: http://docs.oasis-open.org/mqtt/mqtt/v3.1.1/mqtt-v3.1.1.html Use the is_successful method to test whether the connection was successfully initiated.

Implementations

impl ConnectionStatus[src]

pub fn is_successful(&self) -> bool[src]

Returns true if the connection attempt was successful.

Trait Implementations

impl Clone for ConnectionStatus[src]

impl Copy for ConnectionStatus[src]

impl Debug for ConnectionStatus[src]

impl Display for ConnectionStatus[src]

impl Eq for ConnectionStatus[src]

impl PartialEq<ConnectionStatus> for ConnectionStatus[src]

impl StructuralEq for ConnectionStatus[src]

impl StructuralPartialEq for ConnectionStatus[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> ToString for T where
    T: Display + ?Sized
[src]

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.