downcast_rs

Trait DowncastSend

Source
pub trait DowncastSend: Downcast + Send {
    // Required method
    fn into_any_send(self: Box<Self>) -> Box<dyn Any + Send>;
}
Expand description

Extends Downcast for Send traits to support upcasting to Box<dyn Any + Send> as well.

Required Methods§

Source

fn into_any_send(self: Box<Self>) -> Box<dyn Any + Send>

Converts Box<Trait> (where Trait: DowncastSend) to Box<dyn Any + Send>, which can then be downcast into Box<ConcreteType> where ConcreteType implements Trait.

Implementors§

Source§

impl<T: Any + Send> DowncastSend for T