1 /*
2  * This file is part of gtkD.
3  *
4  * gtkD is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU Lesser General Public License
6  * as published by the Free Software Foundation; either version 3
7  * of the License, or (at your option) any later version, with
8  * some exceptions, please read the COPYING file.
9  *
10  * gtkD is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  * GNU Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public License
16  * along with gtkD; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA
18  */
19 
20 // generated automatically - do not change
21 // find conversion definition on APILookup.txt
22 // implement new conversion functionalities on the wrap.utils pakage
23 
24 
25 module gstreamer.URIHandlerIF;
26 
27 private import glib.ErrorG;
28 private import glib.GException;
29 private import glib.Str;
30 private import gstreamerc.gstreamer;
31 public  import gstreamerc.gstreamertypes;
32 
33 
34 /**
35  * The #GstURIHandler is an interface that is implemented by Source and Sink
36  * #GstElement to unify handling of URI.
37  * 
38  * An application can use the following functions to quickly get an element
39  * that handles the given URI for reading or writing
40  * (gst_element_make_from_uri()).
41  * 
42  * Source and Sink plugins should implement this interface when possible.
43  */
44 public interface URIHandlerIF{
45 	/** Get the main Gtk struct */
46 	public GstURIHandler* getURIHandlerStruct();
47 
48 	/** the main Gtk struct as a void* */
49 	protected void* getStruct();
50 
51 	/**
52 	 */
53 
54 	/**
55 	 * Gets the list of protocols supported by @handler. This list may not be
56 	 * modified.
57 	 *
58 	 * Return: the
59 	 *     supported protocols.  Returns %NULL if the @handler isn't
60 	 *     implemented properly, or the @handler doesn't support any
61 	 *     protocols.
62 	 */
63 	public string[] getProtocols();
64 
65 	/**
66 	 * Gets the currently handled URI.
67 	 *
68 	 * Return: the URI currently handled by
69 	 *     the @handler.  Returns %NULL if there are no URI currently
70 	 *     handled. The returned string must be freed with g_free() when no
71 	 *     longer needed.
72 	 */
73 	public string getUri();
74 
75 	/**
76 	 * Gets the type of the given URI handler
77 	 *
78 	 * Return: the #GstURIType of the URI handler.
79 	 *     Returns #GST_URI_UNKNOWN if the @handler isn't implemented correctly.
80 	 */
81 	public GstURIType getUriType();
82 
83 	/**
84 	 * Tries to set the URI of the given handler.
85 	 *
86 	 * Params:
87 	 *     uri = URI to set
88 	 *
89 	 * Return: %TRUE if the URI was set successfully, else %FALSE.
90 	 *
91 	 * Throws: GException on failure.
92 	 */
93 	public bool setUri(string uri);
94 }