soroban_env_common

Trait Convert

Source
pub trait Convert<F, T> {
    type Error: Debug + Into<Error>;

    // Required method
    fn convert(&self, f: F) -> Result<T, Self::Error>;
}
Expand description

General trait representing a the ability of some object to perform a (possibly unsuccessful) conversion between two other types.

Required Associated Types§

Required Methods§

Source

fn convert(&self, f: F) -> Result<T, Self::Error>

Implementors§