Copyright | Will Thompson Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | None |
Language | Haskell2010 |
DynamicTypeFactory
is used to represent a type that can be
automatically loaded the first time it is used. For example,
a non-standard type for use in caps fields.
In general, applications and plugins don't need to use the factory beyond registering the type in a plugin init function. Once that is done, the type is stored in the registry, and ready as soon as the registry is loaded.
Registering a type for dynamic loading
C code
static gboolean plugin_init (GstPlugin * plugin) { return gst_dynamic_type_register (plugin, GST_TYPE_CUSTOM_CAPS_FIELD); }
Synopsis
- newtype DynamicTypeFactory = DynamicTypeFactory (ManagedPtr DynamicTypeFactory)
- class (GObject o, IsDescendantOf DynamicTypeFactory o) => IsDynamicTypeFactory o
- toDynamicTypeFactory :: (MonadIO m, IsDynamicTypeFactory o) => o -> m DynamicTypeFactory
- noDynamicTypeFactory :: Maybe DynamicTypeFactory
- dynamicTypeFactoryLoad :: (HasCallStack, MonadIO m) => Text -> m GType
Exported types
newtype DynamicTypeFactory Source #
Memory-managed wrapper type.
Instances
Eq DynamicTypeFactory Source # | |
Defined in GI.Gst.Objects.DynamicTypeFactory (==) :: DynamicTypeFactory -> DynamicTypeFactory -> Bool # (/=) :: DynamicTypeFactory -> DynamicTypeFactory -> Bool # | |
GObject DynamicTypeFactory Source # | |
Defined in GI.Gst.Objects.DynamicTypeFactory gobjectType :: IO GType # | |
IsGValue DynamicTypeFactory Source # | Convert |
Defined in GI.Gst.Objects.DynamicTypeFactory toGValue :: DynamicTypeFactory -> IO GValue # fromGValue :: GValue -> IO DynamicTypeFactory # | |
HasParentTypes DynamicTypeFactory Source # | |
Defined in GI.Gst.Objects.DynamicTypeFactory | |
type ParentTypes DynamicTypeFactory Source # | |
Defined in GI.Gst.Objects.DynamicTypeFactory |
class (GObject o, IsDescendantOf DynamicTypeFactory o) => IsDynamicTypeFactory o Source #
Type class for types which can be safely cast to DynamicTypeFactory
, for instance with toDynamicTypeFactory
.
Instances
(GObject o, IsDescendantOf DynamicTypeFactory o) => IsDynamicTypeFactory o Source # | |
Defined in GI.Gst.Objects.DynamicTypeFactory |
toDynamicTypeFactory :: (MonadIO m, IsDynamicTypeFactory o) => o -> m DynamicTypeFactory Source #
Cast to DynamicTypeFactory
, for types for which this is known to be safe. For general casts, use castTo
.
noDynamicTypeFactory :: Maybe DynamicTypeFactory Source #
A convenience alias for Nothing
:: Maybe
DynamicTypeFactory
.
Methods
Overloaded methods
load
dynamicTypeFactoryLoad :: (HasCallStack, MonadIO m) => Text -> m GType Source #
No description available in the introspection data.