pub trait Interface {
// Required methods
unsafe fn make_native(&self) -> *mut CInterface;
unsafe fn free_native(cpu: *mut CInterface)
where Self: Sized;
// Provided method
fn type_id(&self) -> TypeId
where Self: 'static { ... }
}Required Methods§
Sourceunsafe fn make_native(&self) -> *mut CInterface
unsafe fn make_native(&self) -> *mut CInterface
Return a C-compatible spa_interface pointer
§Safety
The caller must manually free the returned pointer using free_native().
Sourceunsafe fn free_native(cpu: *mut CInterface)where
Self: Sized,
unsafe fn free_native(cpu: *mut CInterface)where
Self: Sized,
Return a C-compatible spa_interface pointer
§Safety
The pointer must have been allocated using make_native().