org.luaj.vm2.LuaNil Java Examples
The following examples show how to use
org.luaj.vm2.LuaNil.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: DebugLib.java From VideoOS-Android-SDK with GNU General Public License v3.0 | 6 votes |
public LuaValue call(LuaValue value, LuaValue table) { LuaValue mt = table.opttable(null); switch (value.type()) { case TNIL: LuaNil.s_metatable = mt; break; case TNUMBER: LuaNumber.s_metatable = mt; break; case TBOOLEAN: LuaBoolean.s_metatable = mt; break; case TSTRING: LuaString.s_metatable = mt; break; case TFUNCTION: LuaFunction.s_metatable = mt; break; case TTHREAD: LuaThread.s_metatable = mt; break; default: value.setmetatable(mt); } return value; }
Example #2
Source File: DebugLib.java From XPrivacyLua with GNU General Public License v3.0 | 5 votes |
public LuaValue call(LuaValue value, LuaValue table) { LuaValue mt = table.opttable(null); switch ( value.type() ) { case TNIL: LuaNil.s_metatable = mt; break; case TNUMBER: LuaNumber.s_metatable = mt; break; case TBOOLEAN: LuaBoolean.s_metatable = mt; break; case TSTRING: LuaString.s_metatable = mt; break; case TFUNCTION: LuaFunction.s_metatable = mt; break; case TTHREAD: LuaThread.s_metatable = mt; break; default: value.setmetatable( mt ); } return value; }
Example #3
Source File: DebugLib.java From HtmlNative with Apache License 2.0 | 5 votes |
public LuaValue call(LuaValue value, LuaValue table) { LuaValue mt = table.opttable(null); switch ( value.type() ) { case TNIL: LuaNil.s_metatable = mt; break; case TNUMBER: LuaNumber.s_metatable = mt; break; case TBOOLEAN: LuaBoolean.s_metatable = mt; break; case TSTRING: LuaString.s_metatable = mt; break; case TFUNCTION: LuaFunction.s_metatable = mt; break; case TTHREAD: LuaThread.s_metatable = mt; break; default: value.setmetatable( mt ); } return value; }
Example #4
Source File: DebugLib.java From luaj with MIT License | 5 votes |
public LuaValue call(LuaValue value, LuaValue table) { LuaValue mt = table.opttable(null); switch ( value.type() ) { case TNIL: LuaNil.s_metatable = mt; break; case TNUMBER: LuaNumber.s_metatable = mt; break; case TBOOLEAN: LuaBoolean.s_metatable = mt; break; case TSTRING: LuaString.s_metatable = mt; break; case TFUNCTION: LuaFunction.s_metatable = mt; break; case TTHREAD: LuaThread.s_metatable = mt; break; default: value.setmetatable( mt ); } return value; }