Output

Trait Output 

Source
pub trait Output:
    Debug
    + Clone
    + PartialEq {
    // Required methods
    fn into_wrapped(source: Self) -> Wrapped;
    fn from_wrapped(wrapped: Wrapped) -> TractResult<Self>;

    // Provided method
    fn wrap(self) -> Wrapped { ... }
}
Expand description

A trait for values produced by expressions.

Required Methods§

Source

fn into_wrapped(source: Self) -> Wrapped

Wraps the fact in the Wrapped type.

Source

fn from_wrapped(wrapped: Wrapped) -> TractResult<Self>

Retrieves the fact from the Wrapped type. Panics if wrapped doesn’t have the right constructor.

Provided Methods§

Source

fn wrap(self) -> Wrapped

Wraps self in the Wrapped type.

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 Output for i64

Source§

impl Output for usize

Implementors§