[][src]Trait abi_stable::erased_types::vtable::GetVtable

pub trait GetVtable<This, Ptr>: ImplType {
    const GET_VTABLE: *const VTable<This, Ptr>;
    fn get_vtable<'a>() -> &'a VTable<This, Ptr>
    where
        This: 'a
, { ... }
fn erased_vtable() -> &'static VTable<ErasedObject, ErasedObject> { ... } }

Returns the vtable used by VirtualWrapper to do dynamic dispatch.

Associated Constants

const GET_VTABLE: *const VTable<This, Ptr>

Loading content...

Provided methods

fn get_vtable<'a>() -> &'a VTable<This, Ptr> where
    This: 'a, 

Retrieves the VTable of the type.

fn erased_vtable() -> &'static VTable<ErasedObject, ErasedObject>

Gets an erased version of the VTable.

Loading content...

Implementors

impl<This, T, P, E> GetVtable<T, P> for This where
    This: ImplType<Interface = E>,
    E: InterfaceType + GetImplFlags,
    Clone: VTableFieldValue<extern "C" fn(_: &P) -> P, E::Clone, T, P>,
    Default: VTableFieldValue<extern "C" fn() -> P, E::Default, T, P>,
    Display: VTableFieldValue<extern "C" fn(_: &T, _: FormattingMode, _: &mut RString) -> RResult<(), ()>, E::Display, T, P>,
    Debug: VTableFieldValue<extern "C" fn(_: &T, _: FormattingMode, _: &mut RString) -> RResult<(), ()>, E::Debug, T, P>,
    Serialize: VTableFieldValue<extern "C" fn(_: &T) -> RResult<RCow<str>, RBoxError>, E::Serialize, T, P>,
    PartialEq: VTableFieldValue<extern "C" fn(_: &T, _: &T) -> bool, E::PartialEq, T, P>,
    Ord: VTableFieldValue<extern "C" fn(_: &T, _: &T) -> RCmpOrdering, E::Ord, T, P>,
    PartialOrd: VTableFieldValue<extern "C" fn(_: &T, _: &T) -> ROption<RCmpOrdering>, E::PartialOrd, T, P>,
    Hash: VTableFieldValue<extern "C" fn(_: &T, _: HasherTraitObject<&mut ErasedObject>), E::Hash, T, P>, 
[src]

fn get_vtable<'a>() -> &'a VTable<This, Ptr> where
    This: 'a, 
[src]

fn erased_vtable() -> &'static VTable<ErasedObject, ErasedObject>[src]

Loading content...