summaryrefslogtreecommitdiff
path: root/vapi/gmodule-2.0.vapi
blob: 2c308539bfb00cc4cac61f4f36d677bc4d081c3c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
/* gmodule-2.0.vala
 *
 * Copyright (C) 2006-2008  Jürg Billeter
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.

 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.

 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301  USA
 *
 * Author:
 * 	Jürg Billeter <j@bitron.ch>
 */

[CCode (cprefix = "G", lower_case_cprefix = "g_", cheader_filename = "gmodule.h")]
namespace GLib {
	/* Dynamic Loading of Modules */
	
	[Compact]
	[CCode (free_function = "g_module_close", cheader_filename = "gmodule.h")]
	public class Module {
		public const string SUFFIX;
		public static bool supported ();
		public static string build_path (string? directory, string module_name);
		public static Module? open (string? file_name, ModuleFlags flags);
		public bool symbol (string symbol_name, out void* symbol);
		public unowned string name ();
		public void make_resident ();
		public static unowned string error ();
	}
	
	[CCode (cprefix = "G_MODULE_")]
	public enum ModuleFlags {
		BIND_LAZY,
		BIND_LOCAL,
		BIND_MASK
	}
}