Skip to main content

IsSubclassable

Trait IsSubclassable 

Source
pub unsafe trait IsSubclassable<T>: IsSubclassableDefault<T>
where T: ObjectSubclass,
{ // Provided methods fn class_init(class: &mut Class<Self>) { ... } fn instance_init(instance: &mut InitializingObject<T>) { ... } }
Expand description

Trait for subclassable class structs.

Provided Methods§

Source

fn class_init(class: &mut Class<Self>)

Override the virtual methods of this class for the given subclass and do other class initialization.

This is automatically called during type initialization and must call class_init() of the parent class.

Source

fn instance_init(instance: &mut InitializingObject<T>)

Instance specific initialization.

This is automatically called during instance initialization and must call instance_init() of the parent class.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl<T> IsSubclassable<T> for Application
where T: ApplicationImpl,

Source§

impl<T> IsSubclassable<T> for DBusProxy
where T: DBusProxyImpl,

Source§

impl<T> IsSubclassable<T> for FileEnumerator

Source§

impl<T> IsSubclassable<T> for FileMonitor
where T: FileMonitorImpl,

Source§

impl<T> IsSubclassable<T> for IOStream
where T: IOStreamImpl,

Source§

impl<T> IsSubclassable<T> for InputStream
where T: InputStreamImpl,

Source§

impl<T> IsSubclassable<T> for OutputStream

Source§

impl<T> IsSubclassable<T> for SocketControlMessage

Source§

impl<T> IsSubclassable<T> for Vfs
where T: VfsImpl,

Source§

fn class_init(class: &mut Class<Vfs>)

Implementors§