pub struct CMSimpleQueue(/* private fields */);Implementations§
Source§impl CMSimpleQueue
impl CMSimpleQueue
pub fn new(capacity: i32) -> Result<CMSimpleQueue, OSStatus>
pub fn enqueue(&self, element: *const c_void) -> Result<(), OSStatus>
pub fn dequeue(&self) -> *const c_void
pub fn get_head(&self) -> *const c_void
pub fn reset(&self) -> Result<(), OSStatus>
pub fn get_capacity(&self) -> i32
pub fn get_count(&self) -> i32
Trait Implementations§
Source§impl Clone for CMSimpleQueue
impl Clone for CMSimpleQueue
Source§impl Debug for CMSimpleQueue
impl Debug for CMSimpleQueue
Source§impl Drop for CMSimpleQueue
impl Drop for CMSimpleQueue
Source§impl PartialEq for CMSimpleQueue
impl PartialEq for CMSimpleQueue
Source§impl TCFType for CMSimpleQueue
impl TCFType for CMSimpleQueue
Source§type Ref = *mut opaqueCMSimpleQueue
type Ref = *mut opaqueCMSimpleQueue
The reference type wrapped inside this type.
Source§fn as_concrete_TypeRef(&self) -> CMSimpleQueueRef
fn as_concrete_TypeRef(&self) -> CMSimpleQueueRef
Returns the object as its concrete
TypeRef.Source§unsafe fn wrap_under_get_rule(reference: CMSimpleQueueRef) -> Self
unsafe fn wrap_under_get_rule(reference: CMSimpleQueueRef) -> Self
Returns an instance of the object, wrapping the underlying
CFTypeRef subclass. Use this
when following Core Foundation’s “Get Rule”. The reference count is bumped.Source§fn as_CFTypeRef(&self) -> CFTypeRef
fn as_CFTypeRef(&self) -> CFTypeRef
Returns the object as a raw
CFTypeRef. The reference count is not adjusted.Source§unsafe fn wrap_under_create_rule(reference: CMSimpleQueueRef) -> Self
unsafe fn wrap_under_create_rule(reference: CMSimpleQueueRef) -> Self
Returns an instance of the object, wrapping the underlying
CFTypeRef subclass. Use this
when following Core Foundation’s “Create Rule”. The reference count is not bumped.Source§fn as_CFType(&self) -> CFType
fn as_CFType(&self) -> CFType
Returns the object as a wrapped
CFType. The reference count is incremented by one.Source§fn into_CFType(self) -> CFTypewhere
Self: Sized,
fn into_CFType(self) -> CFTypewhere
Self: Sized,
Returns the object as a wrapped
CFType. Consumes self and avoids changing the reference
count.Source§fn retain_count(&self) -> isize
fn retain_count(&self) -> isize
Returns the reference count of the object. It is unwise to do anything other than test
whether the return value of this method is greater than zero.
Source§fn instance_of<OtherCFType>(&self) -> boolwhere
OtherCFType: TCFType,
fn instance_of<OtherCFType>(&self) -> boolwhere
OtherCFType: TCFType,
Returns
true if this value is an instance of another type.Source§impl<'a> ToVoid<CMSimpleQueue> for &'a CMSimpleQueue
impl<'a> ToVoid<CMSimpleQueue> for &'a CMSimpleQueue
Source§impl ToVoid<CMSimpleQueue> for CMSimpleQueueRef
impl ToVoid<CMSimpleQueue> for CMSimpleQueueRef
Source§impl ToVoid<CMSimpleQueue> for CMSimpleQueue
impl ToVoid<CMSimpleQueue> for CMSimpleQueue
impl ConcreteCFType for CMSimpleQueue
impl Eq for CMSimpleQueue
Auto Trait Implementations§
impl Freeze for CMSimpleQueue
impl RefUnwindSafe for CMSimpleQueue
impl !Send for CMSimpleQueue
impl !Sync for CMSimpleQueue
impl Unpin for CMSimpleQueue
impl UnwindSafe for CMSimpleQueue
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