diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2012-12-21 15:44:55 +0100 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2012-12-21 15:44:55 +0100 |
commit | 7571a2e2097e0ad0d4411144786329db507a2325 (patch) | |
tree | 6a0a1578e296b70952547125bf499d5c9aad008a /lib | |
parent | 3cdb867f1baa91cb8aa873e295b30fcb4b52c588 (diff) | |
download | ffi-efl-7571a2e2097e0ad0d4411144786329db507a2325.zip ffi-efl-7571a2e2097e0ad0d4411144786329db507a2325.tar.gz |
generate efreet_ini native binding
Diffstat (limited to 'lib')
-rw-r--r-- | lib/efl/native/efreet_ini.rb | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/lib/efl/native/efreet_ini.rb b/lib/efl/native/efreet_ini.rb new file mode 100644 index 0000000..88c77ab --- /dev/null +++ b/lib/efl/native/efreet_ini.rb @@ -0,0 +1,68 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +# +module Efl + # + module EfreetIni + # + FCT_PREFIX = 'efreet_ini_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'efreet' + # + # TYPEDEFS + # typedef struct Efreet_Ini Efreet_Ini; + typedef :pointer, :efreet_ini + # + # FUNCTIONS + fcts = [ + # EAPI Efreet_Ini *efreet_ini_new(const char *file); + [ :efreet_ini_new, [ :string ], :efreet_ini ], + # EAPI void efreet_ini_free(Efreet_Ini *ini); + [ :efreet_ini_free, [ :efreet_ini ], :void ], + # EAPI int efreet_ini_save(Efreet_Ini *ini, const char *path); + [ :efreet_ini_save, [ :efreet_ini, :string ], :int ], + # EAPI int efreet_ini_section_set(Efreet_Ini *ini, const char *section); + [ :efreet_ini_section_set, [ :efreet_ini, :string ], :int ], + # EAPI void efreet_ini_section_add(Efreet_Ini *ini, const char *section); + [ :efreet_ini_section_add, [ :efreet_ini, :string ], :void ], + # EAPI const char *efreet_ini_string_get(Efreet_Ini *ini, const char *key); + [ :efreet_ini_string_get, [ :efreet_ini, :string ], :string ], + # EAPI void efreet_ini_string_set(Efreet_Ini *ini, const char *key, const char *value); + [ :efreet_ini_string_set, [ :efreet_ini, :string, :string ], :void ], + # EAPI const char *efreet_ini_localestring_get(Efreet_Ini *ini, const char *key); + [ :efreet_ini_localestring_get, [ :efreet_ini, :string ], :string ], + # EAPI void efreet_ini_localestring_set(Efreet_Ini *ini, const char *key, const char *value); + [ :efreet_ini_localestring_set, [ :efreet_ini, :string, :string ], :void ], + # EAPI unsigned int efreet_ini_boolean_get(Efreet_Ini *ini, const char *key); + [ :efreet_ini_boolean_get, [ :efreet_ini, :string ], :uint ], + # EAPI void efreet_ini_boolean_set(Efreet_Ini *ini, const char *key, unsigned int value); + [ :efreet_ini_boolean_set, [ :efreet_ini, :string, :uint ], :void ], + # EAPI int efreet_ini_int_get(Efreet_Ini *ini, const char *key); + [ :efreet_ini_int_get, [ :efreet_ini, :string ], :int ], + # EAPI void efreet_ini_int_set(Efreet_Ini *ini, const char *key, int value); + [ :efreet_ini_int_set, [ :efreet_ini, :string, :int ], :void ], + # EAPI double efreet_ini_double_get(Efreet_Ini *ini, const char *key); + [ :efreet_ini_double_get, [ :efreet_ini, :string ], :double ], + # EAPI void efreet_ini_double_set(Efreet_Ini *ini, const char *key, double value); + [ :efreet_ini_double_set, [ :efreet_ini, :string, :double ], :void ], + # EAPI void efreet_ini_key_unset(Efreet_Ini *ini, const char *key); + [ :efreet_ini_key_unset, [ :efreet_ini, :string ], :void ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF |