/ src / libsmoke /
src/libsmoke/cl_smoke.h
1 #ifndef CL_SMOKE_H
2 #define CL_SMOKE_H
3
4 #include <smoke.h>
5
6 #if defined _WIN32 || defined __CYGWIN__
7 #define CL_SMOKE_EXPORT __declspec(dllexport)
8 #else
9 #if __GNUC__ >= 4
10 #define CL_SMOKE_EXPORT __attribute__((visibility("default")))
11 #else
12 #define CL_SMOKE_EXPORT
13 #endif
14 #endif
15
16 /** @brief cl-smoke binding namespace. */
17 namespace cl_smoke
18 {
19 class Binding;
20
21 /** The arrays of the Smoke module */
22 enum cl_smoke_module_array
23 {
24 classes,
25 methods,
26 method_maps,
27 method_names,
28 types,
29 inheritance_list,
30 argument_list,
31 ambiguous_method_list
32 };
33
34 /** A Binding */
35 typedef void* smoke_binding;
36
37 /** Casts the void pointer smoke to the Smoke class.
38 * @param smoke the Smoke module
39 *
40 * @return pointer to the Smoke module.
41 */
42 static inline
43 Smoke*
44 get_smoke(void* smoke)
45 {
46 return static_cast<Smoke*>(smoke);
47 }
48 } // namespace cl_smoke
49
50 #endif // CL_SMOKE_H