pub struct CMClock(/* private fields */);Implementations§
Source§impl CMClock
impl CMClock
pub fn new_audio_device_clock( device_uid: &CFString, ) -> Result<CMClock, OSStatus>
pub fn new_audio_device_clock_from_device_id( device_id: AudioDeviceID, ) -> Result<CMClock, OSStatus>
pub fn set_audio_device_uid( &self, device_uid: &CFString, ) -> Result<(), OSStatus>
pub fn set_audio_device_id( &self, device_id: AudioDeviceID, ) -> Result<(), OSStatus>
pub fn get_audio_device( &self, ) -> Result<(CFString, AudioDeviceID, Boolean), OSStatus>
Source§impl CMClock
impl CMClock
pub fn get_host_time_clock() -> Self
pub fn convert_host_time_to_system_units(host_time: CMTime) -> u64
pub fn make_host_time_from_system_units(host_time: u64) -> CMTime
pub fn get_time(&self) -> CMTime
pub fn get_anchor_time(&self) -> Result<(CMTime, CMTime), OSStatus>
pub fn might_drift(&self, other_clock: &CMClock) -> bool
pub fn invalidate(&self)
Trait Implementations§
Source§impl TCFType for CMClock
impl TCFType for CMClock
Source§type Ref = *mut OpaqueCMClock
type Ref = *mut OpaqueCMClock
The reference type wrapped inside this type.
Source§fn as_concrete_TypeRef(&self) -> CMClockRef
fn as_concrete_TypeRef(&self) -> CMClockRef
Returns the object as its concrete
TypeRef.Source§unsafe fn wrap_under_get_rule(reference: CMClockRef) -> Self
unsafe fn wrap_under_get_rule(reference: CMClockRef) -> 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: CMClockRef) -> Self
unsafe fn wrap_under_create_rule(reference: CMClockRef) -> 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.impl ConcreteCFType for CMClock
impl Eq for CMClock
Auto Trait Implementations§
impl Freeze for CMClock
impl RefUnwindSafe for CMClock
impl !Send for CMClock
impl !Sync for CMClock
impl Unpin for CMClock
impl UnwindSafe for CMClock
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