FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    AsyncState

    enum · ferroui-view · v0.5.0

    enum AsyncState<T>
    

    The state of an asynchronous operation: pending until it ends, then its value or the message of its error.

    View source

    Members

    Pending

    Pending
    

    The operation has not ended.

    Source

    Ready

    Ready(T)
    

    The operation ended with a value.

    Source

    Failed

    Failed(String)
    

    The operation ended with an error.

    Source

    is_pending

    fn is_pending(self: &Self) -> bool
    

    Whether the operation has not ended.

    Source

    value

    fn value(self: &Self) -> Option<&T>
    

    The value, once the operation ended with one.

    Source

    error

    fn error(self: &Self) -> Option<&str>
    

    The message of the error, once the operation failed.

    Source

    Trait implementations

    Availability

    Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.