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  * Conversion parameters:
26  * inFile  = GLoadableIcon.html
27  * outPack = gio
28  * outFile = LoadableIconIF
29  * strct   = GLoadableIcon
30  * realStrct=
31  * ctorStrct=
32  * clss    = LoadableIconT
33  * interf  = LoadableIconIF
34  * class Code: No
35  * interface Code: No
36  * template for:
37  * extend  = 
38  * implements:
39  * prefixes:
40  * 	- g_loadable_icon_
41  * omit structs:
42  * omit prefixes:
43  * omit code:
44  * omit signals:
45  * imports:
46  * 	- glib.Str
47  * 	- glib.ErrorG
48  * 	- glib.GException
49  * 	- gio.AsyncResultIF
50  * 	- gio.Cancellable
51  * 	- gio.InputStream
52  * structWrap:
53  * 	- GAsyncResult* -> AsyncResultIF
54  * 	- GCancellable* -> Cancellable
55  * 	- GInputStream* -> InputStream
56  * module aliases:
57  * local aliases:
58  * overrides:
59  */
60 
61 module gio.LoadableIconIF;
62 
63 public  import gtkc.giotypes;
64 
65 private import gtkc.gio;
66 private import glib.ConstructionException;
67 private import gobject.ObjectG;
68 
69 private import glib.Str;
70 private import glib.ErrorG;
71 private import glib.GException;
72 private import gio.AsyncResultIF;
73 private import gio.Cancellable;
74 private import gio.InputStream;
75 
76 
77 
78 /**
79  * Extends the GIcon interface and adds the ability to
80  * load icons from streams.
81  */
82 public interface LoadableIconIF
83 {
84 	
85 	
86 	/** Get the main Gtk struct */
87 	public GLoadableIcon* getLoadableIconTStruct();
88 	
89 	/** the main Gtk struct as a void* */
90 	protected void* getStruct();
91 	
92 	
93 	/**
94 	 */
95 	
96 	/**
97 	 * Loads a loadable icon. For the asynchronous version of this function,
98 	 * see g_loadable_icon_load_async().
99 	 * Params:
100 	 * size = an integer.
101 	 * type = a location to store the type of the
102 	 * loaded icon, NULL to ignore. [out][allow-none]
103 	 * cancellable = optional GCancellable object, NULL to ignore. [allow-none]
104 	 * Returns: a GInputStream to read the icon from. [transfer full]
105 	 * Throws: GException on failure.
106 	 */
107 	public InputStream load(int size, out string type, Cancellable cancellable);
108 	
109 	/**
110 	 * Loads an icon asynchronously. To finish this function, see
111 	 * g_loadable_icon_load_finish(). For the synchronous, blocking
112 	 * version of this function, see g_loadable_icon_load().
113 	 * Params:
114 	 * size = an integer.
115 	 * cancellable = optional GCancellable object, NULL to ignore. [allow-none]
116 	 * callback = a GAsyncReadyCallback to call when the
117 	 * request is satisfied. [scope async]
118 	 * userData = the data to pass to callback function. [closure]
119 	 */
120 	public void loadAsync(int size, Cancellable cancellable, GAsyncReadyCallback callback, void* userData);
121 	
122 	/**
123 	 * Finishes an asynchronous icon load started in g_loadable_icon_load_async().
124 	 * Params:
125 	 * res = a GAsyncResult.
126 	 * type = a location to store the type of the
127 	 * loaded icon, NULL to ignore. [out][allow-none]
128 	 * Returns: a GInputStream to read the icon from. [transfer full]
129 	 * Throws: GException on failure.
130 	 */
131 	public InputStream loadFinish(AsyncResultIF res, out string type);
132 }