Struct gstreamer::SystemClock [−]
pub struct SystemClock(_, _);
The GStreamer core provides a GstSystemClock based on the system time. Asynchronous callbacks are scheduled from an internal thread.
Clock implementors are encouraged to subclass this systemclock as it implements the async notification.
Subclasses can however override all of the important methods for sync and async notifications to implement their own callback methods or blocking wait operations.
Implements
SystemClockExt
, ClockExt
, GstObjectExt
, glib::object::ObjectExt
Methods
impl SystemClock
[src]
impl SystemClock
pub fn obtain() -> Clock
[src]
pub fn obtain() -> Clock
Get a handle to the default system clock. The refcount of the clock will be increased so you need to unref the clock after usage.
Returns
the default clock.
MT safe.
pub fn set_default<'a, P: IsA<Clock> + 'a, Q: Into<Option<&'a P>>>(new_clock: Q)
[src]
pub fn set_default<'a, P: IsA<Clock> + 'a, Q: Into<Option<&'a P>>>(new_clock: Q)
Sets the default system clock that can be obtained with
SystemClock::obtain
.
This is mostly used for testing and debugging purposes when you want to have control over the time reported by the default system clock.
MT safe.
new_clock
a Clock
Trait Implementations
impl Clone for SystemClock
impl Clone for SystemClock
fn clone(&self) -> SystemClock
fn clone(&self) -> SystemClock
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Hash for SystemClock
impl Hash for SystemClock
fn hash<__H: Hasher>(&self, state: &mut __H)
fn hash<__H: Hasher>(&self, state: &mut __H)
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl Ord for SystemClock
impl Ord for SystemClock
fn cmp(&self, other: &SystemClock) -> Ordering
fn cmp(&self, other: &SystemClock) -> Ordering
This method returns an Ordering
between self
and other
. Read more
fn max(self, other: Self) -> Self
1.21.0[src]
fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
impl StaticType for SystemClock
impl StaticType for SystemClock
fn static_type() -> Type
fn static_type() -> Type
Returns the type identifier of Self
.
impl<T: IsA<Object>> PartialEq<T> for SystemClock
impl<T: IsA<Object>> PartialEq<T> for SystemClock
fn eq(&self, other: &T) -> bool
fn eq(&self, other: &T) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
#[must_use]
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl Eq for SystemClock
impl Eq for SystemClock
impl<T: IsA<Object>> PartialOrd<T> for SystemClock
impl<T: IsA<Object>> PartialOrd<T> for SystemClock
fn partial_cmp(&self, other: &T) -> Option<Ordering>
fn partial_cmp(&self, other: &T) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
#[must_use]
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
#[must_use]
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
#[must_use]
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
#[must_use]
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Debug for SystemClock
impl Debug for SystemClock
impl IsA<Clock> for SystemClock
impl IsA<Clock> for SystemClock
impl IsA<Object> for SystemClock
impl IsA<Object> for SystemClock
impl IsA<Object> for SystemClock
impl IsA<Object> for SystemClock
impl Send for SystemClock
[src]
impl Send for SystemClock
impl Sync for SystemClock
[src]
impl Sync for SystemClock