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 
70 private import glib.Str;
71 private import glib.ErrorG;
72 private import glib.GException;
73 private import gio.AsyncResultIF;
74 private import gio.Cancellable;
75 private import gio.InputStream;
76 
77 
78 
79 
80 /**
81  * Description
82  * Extends the GIcon interface and adds the ability to
83  * load icons from streams.
84  */
85 public interface LoadableIconIF
86 {
87 	
88 	
89 	public GLoadableIcon* getLoadableIconTStruct();
90 	
91 	/** the main Gtk struct as a void* */
92 	protected void* getStruct();
93 	
94 	
95 	/**
96 	 */
97 	
98 	/**
99 	 * Loads a loadable icon. For the asynchronous version of this function,
100 	 * see g_loadable_icon_load_async().
101 	 * Params:
102 	 * size = an integer.
103 	 * type = a location to store the type of the
104 	 * loaded icon, NULL to ignore. [out][allow-none]
105 	 * cancellable = optional GCancellable object, NULL to ignore. [allow-none]
106 	 * Returns: a GInputStream to read the icon from. [transfer full]
107 	 * Throws: GException on failure.
108 	 */
109 	public InputStream load(int size, out string type, Cancellable cancellable);
110 	
111 	/**
112 	 * Loads an icon asynchronously. To finish this function, see
113 	 * g_loadable_icon_load_finish(). For the synchronous, blocking
114 	 * version of this function, see g_loadable_icon_load().
115 	 * Params:
116 	 * size = an integer.
117 	 * cancellable = optional GCancellable object, NULL to ignore. [allow-none]
118 	 * callback = a GAsyncReadyCallback to call when the
119 	 * request is satisfied. [scope async]
120 	 * userData = the data to pass to callback function. [closure]
121 	 */
122 	public void loadAsync(int size, Cancellable cancellable, GAsyncReadyCallback callback, void* userData);
123 	
124 	/**
125 	 * Finishes an asynchronous icon load started in g_loadable_icon_load_async().
126 	 * Params:
127 	 * res = a GAsyncResult.
128 	 * type = a location to store the type of the loaded icon, NULL to ignore.
129 	 * Returns: a GInputStream to read the icon from. [transfer full]
130 	 * Throws: GException on failure.
131 	 */
132 	public InputStream loadFinish(AsyncResultIF res, out string type);
133 }