pub struct CFRunLoop(/* private fields */);Expand description
Safe wrapper around a retained Core Foundation CFRunLoop reference.
Implementations§
Source§impl CFRunLoop
impl CFRunLoop
Sourcepub fn from_raw(ptr: *mut c_void) -> Option<Self>
pub fn from_raw(ptr: *mut c_void) -> Option<Self>
Wraps a +1 retained CFRunLoop pointer and returns None for null.
Sourcepub unsafe fn from_raw_retained(ptr: *mut c_void) -> Option<Self>
pub unsafe fn from_raw_retained(ptr: *mut c_void) -> Option<Self>
Retains a +0 borrowed CFRunLoop pointer and wraps the resulting +1 reference.
§Safety
ptr must be NULL or a valid CFRunLoop pointer.
Sourcepub fn into_cf_type(self) -> CFType
pub fn into_cf_type(self) -> CFType
Consumes this wrapper and returns the erased CFType.
Source§impl CFRunLoop
impl CFRunLoop
Sourcepub fn run_in_default_mode(
&self,
duration: Duration,
return_after_source_handled: bool,
) -> CFRunLoopRunResult
pub fn run_in_default_mode( &self, duration: Duration, return_after_source_handled: bool, ) -> CFRunLoopRunResult
Run the current thread’s run loop in the default mode for duration.
Trait Implementations§
impl Eq for CFRunLoop
impl StructuralPartialEq for CFRunLoop
Auto Trait Implementations§
impl Freeze for CFRunLoop
impl RefUnwindSafe for CFRunLoop
impl !Send for CFRunLoop
impl !Sync for CFRunLoop
impl Unpin for CFRunLoop
impl UnsafeUnpin for CFRunLoop
impl UnwindSafe for CFRunLoop
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