Trait Resolvable

Source
pub trait Resolvable<T: Committable>: Sized {
    // Required methods
    fn try_resolve(self) -> Result<T, Self>;
    fn commitment(&self) -> Commitment<T>;
}
Expand description

A reference to a T which can be resolved into a whole T.

Required Methods§

Source

fn try_resolve(self) -> Result<T, Self>

Get the underlying object if it is available without blocking.

Source

fn commitment(&self) -> Commitment<T>

Get a commitment to the underlying object.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<T: Committable> Resolvable<T> for Either<T, Commitment<T>>

Source§

fn try_resolve(self) -> Result<T, Self>

Source§

fn commitment(&self) -> Commitment<T>

Implementors§

Source§

impl<T: Committable> Resolvable<T> for T