Trait AsAny

Source
pub trait AsAny {
    // Required method
    fn as_any(&self) -> &dyn Any;
}
Expand description

Trait providing type erasure capabilities for command objects.

This trait allows commands to be stored and passed around as trait objects while still providing access to their concrete types when needed for pipeline dispatch.

Required Methods§

Source

fn as_any(&self) -> &dyn Any

Returns a reference to the concrete type as &dyn Any.

Implementors§

Source§

impl<T: Any> AsAny for T

Blanket implementation of AsAny for all types that implement Any.