pub struct Callback { /* private fields */ }Expand description
Timer’s callback abstraction
Implementations§
Source§impl Callback
impl Callback
Sourcepub unsafe fn raw(
ffi_cb: unsafe extern "system" fn(cb_inst: *mut c_void, ctx: *mut c_void, timer: *mut c_void),
data: *mut c_void,
) -> Self
pub unsafe fn raw( ffi_cb: unsafe extern "system" fn(cb_inst: *mut c_void, ctx: *mut c_void, timer: *mut c_void), data: *mut c_void, ) -> Self
Creates raw callback for platform timer.
Signature depends on platform.
Sourcepub fn unsafe_plain(cb: unsafe fn()) -> Self
pub fn unsafe_plain(cb: unsafe fn()) -> Self
Creates callback using plain unsafe function
Auto Trait Implementations§
impl Freeze for Callback
impl !RefUnwindSafe for Callback
impl !Send for Callback
impl !Sync for Callback
impl Unpin for Callback
impl !UnwindSafe for Callback
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more