[][src]Struct tokio::io::Ready

pub struct Ready(_);

Describes the readiness state of an I/O resources.

Ready tracks which operation an I/O resource is ready to perform.

Implementations

impl Ready[src]

pub const EMPTY: Ready[src]

Returns the empty Ready set.

pub const READABLE: Ready[src]

Returns a Ready representing readable readiness.

pub const WRITABLE: Ready[src]

Returns a Ready representing writable readiness.

pub const READ_CLOSED: Ready[src]

Returns a Ready representing read closed readiness.

pub const WRITE_CLOSED: Ready[src]

Returns a Ready representing write closed readiness.

pub const ALL: Ready[src]

Returns a Ready representing readiness for all operations.

pub fn is_empty(self) -> bool[src]

Returns true if Ready is the empty set

Examples

use tokio::io::Ready;

assert!(Ready::EMPTY.is_empty());
assert!(!Ready::READABLE.is_empty());

pub fn is_readable(self) -> bool[src]

Returns true if the value includes readable

Examples

use tokio::io::Ready;

assert!(!Ready::EMPTY.is_readable());
assert!(Ready::READABLE.is_readable());
assert!(Ready::READ_CLOSED.is_readable());
assert!(!Ready::WRITABLE.is_readable());

pub fn is_writable(self) -> bool[src]

Returns true if the value includes writable readiness

Examples

use tokio::io::Ready;

assert!(!Ready::EMPTY.is_writable());
assert!(!Ready::READABLE.is_writable());
assert!(Ready::WRITABLE.is_writable());
assert!(Ready::WRITE_CLOSED.is_writable());

pub fn is_read_closed(self) -> bool[src]

Returns true if the value includes read-closed readiness

Examples

use tokio::io::Ready;

assert!(!Ready::EMPTY.is_read_closed());
assert!(!Ready::READABLE.is_read_closed());
assert!(Ready::READ_CLOSED.is_read_closed());

pub fn is_write_closed(self) -> bool[src]

Returns true if the value includes write-closed readiness

Examples

use tokio::io::Ready;

assert!(!Ready::EMPTY.is_write_closed());
assert!(!Ready::WRITABLE.is_write_closed());
assert!(Ready::WRITE_CLOSED.is_write_closed());

Trait Implementations

impl BitAnd<Ready> for Ready[src]

type Output = Ready

The resulting type after applying the & operator.

impl BitOr<Ready> for Ready[src]

type Output = Ready

The resulting type after applying the | operator.

impl BitOrAssign<Ready> for Ready[src]

impl Clone for Ready[src]

impl Copy for Ready[src]

impl Debug for Ready[src]

impl PartialEq<Ready> for Ready[src]

impl PartialOrd<Ready> for Ready[src]

impl StructuralPartialEq for Ready[src]

impl Sub<Ready> for Ready[src]

type Output = Ready

The resulting type after applying the - operator.

Auto Trait Implementations

impl RefUnwindSafe for Ready

impl Send for Ready

impl Sync for Ready

impl Unpin for Ready

impl UnwindSafe for Ready

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.