pub trait Wrapperwhere
    Self: Deref<Target = Self::RawWrapperType> + DerefMut<Target = Self::RawWrapperType> + AsRef<Self::RawWrapperType> + AsMut<Self::RawWrapperType> + Sized,{
    type RawWrapperType: RawWrapper;

    // Provided methods
    fn into_raw(self) -> *mut <Self::RawWrapperType as RawWrapper>::CType { ... }
    fn as_raw(&self) -> *mut <Self::RawWrapperType as RawWrapper>::CType { ... }
}
Expand description

Owned wrapper for the external type. Should be used when external value can be created or dropped from the Rust side, or when Wrapper should have additional fields. Methods wrappers can be implemented in the RawWrapper and used from the both variants. Usually Wrappers have only constructor and drop implementations.

Required Associated Types§

Provided Methods§

source

fn into_raw(self) -> *mut <Self::RawWrapperType as RawWrapper>::CType

Converts the Wrapper into raw pointer, that must be dropped manually. Used when the external method takes the ownership.

source

fn as_raw(&self) -> *mut <Self::RawWrapperType as RawWrapper>::CType

Raw mutable pointer to the external value.

Implementors§

source§

impl Wrapper for Context

source§

impl Wrapper for Core

source§

impl Wrapper for MainLoop

source§

impl Wrapper for Properties

source§

impl Wrapper for DataLoop

source§

impl Wrapper for Global

source§

impl Wrapper for ImplClient

source§

impl Wrapper for ImplCore

source§

impl Wrapper for Protocol

source§

impl Wrapper for Hook

source§

impl<'a> Wrapper for Stream<'a>

source§

impl<'a, T> Wrapper for Filter<'a, T>

source§

impl<'c> Wrapper for Client<'c>

source§

impl<'c> Wrapper for ContextEvents<'c>

source§

impl<'c> Wrapper for CoreEvents<'c>

source§

impl<'c> Wrapper for Device<'c>

source§

impl<'c> Wrapper for Factory<'c>

source§

impl<'c> Wrapper for Link<'c>

source§

impl<'c> Wrapper for Node<'c>

source§

impl<'c> Wrapper for Port<'c>

source§

impl<'c> Wrapper for Proxy<'c>

source§

impl<'c> Wrapper for Registry<'c>

source§

impl<'f> Wrapper for ClientEvents<'f>

source§

impl<'f> Wrapper for FactoryEvents<'f>

source§

impl<'l> Wrapper for EventSource<'l>

source§

impl<'l> Wrapper for IOSource<'l>

source§

impl<'l> Wrapper for IdleSource<'l>

source§

impl<'l> Wrapper for SignalSource<'l>

source§

impl<'l> Wrapper for TimerSource<'l>

source§

impl<'p> Wrapper for DeviceEvents<'p>

source§

impl<'p> Wrapper for LinkEvents<'p>

source§

impl<'p> Wrapper for NodeEvents<'p>

source§

impl<'p> Wrapper for PortEvents<'p>

source§

impl<'p> Wrapper for ProxyEvents<'p>

source§

impl<'p> Wrapper for StreamEvents<'p>

source§

impl<'p, T> Wrapper for FilterEvents<'p, T>

source§

impl<'r> Wrapper for RegistryEvents<'r>