Derive Macro pipewire_wrapper_proc_macro::Wrapper
source · #[derive(Wrapper)]
{
// Attributes available to this derive:
#[raw_wrapper]
}
Expand description
Implement Wrapper trait.
#[raw_wrapper]
attribute must be added before field with NonNull<impl RawWrapper>
pointer to *Ref
struct, that implements RawWrapper
Examples
ⓘ
#[derive(RawWrapper, Debug)]
#[repr(transparent)]
pub struct MainLoopRef {
#[raw]
raw: pw_sys::pw_main_loop,
}
#[derive(Wrapper, Debug)]
pub struct MainLoop {
#[raw_wrapper]
ref_: NonNull<MainLoopRef>,
pipewire: std::sync::Arc<PipeWire>,
}