Copyright | Will Thompson Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria (inaki@blueleaf.cc) |
Safe Haskell | None |
Language | Haskell2010 |
The URIHandler
is an interface that is implemented by Source and Sink
Element
to unify handling of URI.
An application can use the following functions to quickly get an element
that handles the given URI for reading or writing
(elementMakeFromUri
).
Source and Sink plugins should implement this interface when possible.
Synopsis
- newtype URIHandler = URIHandler (ManagedPtr URIHandler)
- noURIHandler :: Maybe URIHandler
- class ManagedPtrNewtype a => IsURIHandler a
- uRIHandlerGetProtocols :: (HasCallStack, MonadIO m, IsURIHandler a) => a -> m (Maybe [Text])
- uRIHandlerGetUri :: (HasCallStack, MonadIO m, IsURIHandler a) => a -> m (Maybe Text)
- uRIHandlerGetUriType :: (HasCallStack, MonadIO m, IsURIHandler a) => a -> m URIType
- uRIHandlerSetUri :: (HasCallStack, MonadIO m, IsURIHandler a) => a -> Text -> m ()
Exported types
newtype URIHandler Source #
Memory-managed wrapper type.
Instances
WrappedPtr URIHandler Source # | |
Defined in GI.Gst.Interfaces.URIHandler | |
IsURIHandler URIHandler Source # | |
Defined in GI.Gst.Interfaces.URIHandler |
noURIHandler :: Maybe URIHandler Source #
A convenience alias for Nothing
:: Maybe
URIHandler
.
class ManagedPtrNewtype a => IsURIHandler a Source #
Type class for types which implement URIHandler
.
Instances
IsURIHandler URIHandler Source # | |
Defined in GI.Gst.Interfaces.URIHandler |
Methods
getProtocols
uRIHandlerGetProtocols Source #
:: (HasCallStack, MonadIO m, IsURIHandler a) | |
=> a |
|
-> m (Maybe [Text]) | Returns: the
supported protocols. Returns |
Gets the list of protocols supported by handler
. This list may not be
modified.
getUri
:: (HasCallStack, MonadIO m, IsURIHandler a) | |
=> a |
|
-> m (Maybe Text) | Returns: the URI currently handled by
the |
Gets the currently handled URI.
getUriType
:: (HasCallStack, MonadIO m, IsURIHandler a) | |
=> a |
|
-> m URIType | Returns: the |
Gets the type of the given URI handler
setUri
:: (HasCallStack, MonadIO m, IsURIHandler a) | |
=> a |
|
-> Text |
|
-> m () | (Can throw |
Tries to set the URI of the given handler.