Package org.freedesktop.gstreamer.gst
Interface URIHandler
- All Superinterfaces:
Proxy
- All Known Implementing Classes:
AudioCdSrc
,URIHandler.URIHandlerImpl
The
GstURIHandler
is an interface that is implemented by Source and Sink
GstElement
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 (gst_element_make_from_uri()).
Source and Sink plugins should implement this interface when possible.
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic class
The URIHandlerImpl type represents a native instance of the URIHandler interface.static class
AnyGstElement
using this interface should implement these methods. -
Method Summary
Modifier and TypeMethodDescriptiondefault String[]
Gets the list of protocols supported by this URIHandler.static Type
getType()
Get the GType of the URIHandler classdefault String
getUri()
Gets the currently handled URI.default URIType
Gets the type of the given URI handlerdefault boolean
Tries to set the URI of the given handler.
-
Method Details
-
getType
-
getProtocols
Gets the list of protocols supported by this URIHandler. This list may not be modified.- Returns:
- the
supported protocols. Returns
null
if the this URIHandler isn't implemented properly, or the this URIHandler doesn't support any protocols.
-
getUri
Gets the currently handled URI.- Returns:
- the URI currently handled by
the this URIHandler. Returns
null
if there are no URI currently handled. The returned string must be freed with g_free() when no longer needed.
-
getUriType
Gets the type of the given URI handler- Returns:
- the
GstURIType
of the URI handler. ReturnsGST_URI_UNKNOWN
if the this URIHandler isn't implemented correctly.
-
setUri
Tries to set the URI of the given handler.- Parameters:
uri
- URI to set- Returns:
true
if the URI was set successfully, elsefalse
.- Throws:
GErrorException
- seeGError
-