Struct tokio::io::Ready [−][src]
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]
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 BitOrAssign<Ready> for Ready
[src]
impl BitOrAssign<Ready> for Ready
[src]fn bitor_assign(&mut self, other: Ready)
[src]
impl PartialOrd<Ready> for Ready
[src]
impl PartialOrd<Ready> for Ready
[src]