summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDaniel Kolesa <d.kolesa@samsung.com>2019-05-26 18:21:27 +0200
committerDaniel Kolesa <d.kolesa@samsung.com>2019-05-26 18:21:27 +0200
commit891396897b71d1318a822536012def586816febb (patch)
tree9a08a1471a2d2b306ce9cef326bfb7338c545bd2 /src
parent7dcbdef56dbece79e384823e5452c647f460b006 (diff)
elua: add version_get API for units in eolian bindings
Diffstat (limited to 'src')
-rw-r--r--src/bindings/luajit/eolian.lua5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/bindings/luajit/eolian.lua b/src/bindings/luajit/eolian.lua
index 6db54dc0d0..5e60c89771 100644
--- a/src/bindings/luajit/eolian.lua
+++ b/src/bindings/luajit/eolian.lua
@@ -323,6 +323,7 @@ ffi.cdef [[
323 Eina_Iterator *eolian_unit_children_get(const Eolian_Unit *unit); 323 Eina_Iterator *eolian_unit_children_get(const Eolian_Unit *unit);
324 const char *eolian_unit_file_get(const Eolian_Unit *unit); 324 const char *eolian_unit_file_get(const Eolian_Unit *unit);
325 const char *eolian_unit_file_path_get(const Eolian_Unit *unit); 325 const char *eolian_unit_file_path_get(const Eolian_Unit *unit);
326 unsigned short eolian_unit_version_get(const Eolian_Unit *unit);
326 const Eolian_Object *eolian_unit_object_by_name_get(const Eolian_Unit *unit, const char *name); 327 const Eolian_Object *eolian_unit_object_by_name_get(const Eolian_Unit *unit, const char *name);
327 Eina_Iterator *eolian_unit_objects_get(const Eolian_Unit *unit); 328 Eina_Iterator *eolian_unit_objects_get(const Eolian_Unit *unit);
328 const Eolian_Class *eolian_unit_class_by_name_get(const Eolian_Unit *unit, const char *class_name); 329 const Eolian_Class *eolian_unit_class_by_name_get(const Eolian_Unit *unit, const char *class_name);
@@ -638,6 +639,10 @@ local unit_idx, wrap_unit = gen_wrap {
638 return ffi.string(v) 639 return ffi.string(v)
639 end, 640 end,
640 641
642 version_get = function(self)
643 return tonumber(eolian.eolian_unit_version_get(cast_unit(self)))
644 end,
645
641 object_by_name_get = function(self, name) 646 object_by_name_get = function(self, name)
642 local v = eolian.eolian_unit_object_by_name_get(cast_unit(self), name) 647 local v = eolian.eolian_unit_object_by_name_get(cast_unit(self), name)
643 if v == nil then return nil end 648 if v == nil then return nil end