Copyright | Will Thompson, Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria (garetxe@gmail.com) |
Safe Haskell | None |
Language | Haskell2010 |
GI.Gst.Objects.SystemClock
Description
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.
- newtype SystemClock = SystemClock (ManagedPtr SystemClock)
- class GObject o => IsSystemClock o
- toSystemClock :: IsSystemClock o => o -> IO SystemClock
- noSystemClock :: Maybe SystemClock
- systemClockObtain :: (HasCallStack, MonadIO m) => m Clock
- systemClockSetDefault :: (HasCallStack, MonadIO m, IsClock a) => a -> m ()
- data SystemClockClockTypePropertyInfo
- constructSystemClockClockType :: IsSystemClock o => ClockType -> IO (GValueConstruct o)
- getSystemClockClockType :: (MonadIO m, IsSystemClock o) => o -> m ClockType
- setSystemClockClockType :: (MonadIO m, IsSystemClock o) => o -> ClockType -> m ()
- systemClockClockType :: AttrLabelProxy "clockType"
Exported types
newtype SystemClock Source #
Constructors
SystemClock (ManagedPtr SystemClock) |
Instances
GObject SystemClock Source # | |
IsObject SystemClock Source # | |
IsObject SystemClock Source # | |
IsClock SystemClock Source # | |
IsSystemClock SystemClock Source # | |
((~) * info (ResolveSystemClockMethod t SystemClock), MethodInfo * info SystemClock p) => IsLabel t (SystemClock -> p) Source # | |
((~) * info (ResolveSystemClockMethod t SystemClock), MethodInfo * info SystemClock p) => IsLabelProxy t (SystemClock -> p) Source # | |
HasAttributeList * SystemClock Source # | |
type AttributeList SystemClock Source # | |
type SignalList SystemClock Source # | |
class GObject o => IsSystemClock o Source #
Instances
toSystemClock :: IsSystemClock o => o -> IO SystemClock Source #
Methods
obtain
Arguments
:: (HasCallStack, MonadIO m) | |
=> m Clock | Returns: the default clock. MT safe. |
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.
setDefault
systemClockSetDefault Source #
Arguments
:: (HasCallStack, MonadIO m, IsClock a) | |
=> a |
|
-> m () |
Sets the default system clock that can be obtained with
systemClockObtain
.
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.
Since: 1.4
Properties
clockType
data SystemClockClockTypePropertyInfo Source #
Instances
constructSystemClockClockType :: IsSystemClock o => ClockType -> IO (GValueConstruct o) Source #
getSystemClockClockType :: (MonadIO m, IsSystemClock o) => o -> m ClockType Source #
setSystemClockClockType :: (MonadIO m, IsSystemClock o) => o -> ClockType -> m () Source #
systemClockClockType :: AttrLabelProxy "clockType" Source #