Trait Object

Source
pub trait Object:
    From<Family<Self>>
    + Sized
    + Clone
    + 'static {
    // Required method
    fn family(&self) -> Family<Self>;
}
Expand description

Operations available on every instance of a linked object.

The only supported way to implement this is via #[linked::object].

Required Methods§

Source

fn family(&self) -> Family<Self>

The object family that the current instance is linked to.

The returned object can be used to create additional instances linked to the same family.

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.

Implementors§

Source§

impl<T: ?Sized + 'static> Object for Box<T>