Helper class to coerce values from lua to Java within the luajava library.
This class is primarily used by the {@link LuajavaLib}, but can also be used directly when working with Java/lua bindings.
To coerce to specific Java values, generally the {@code toType()} methods on {@link LuaValue} may be used:
- {@link LuaValue#toboolean()}
- {@link LuaValue#tobyte()}
- {@link LuaValue#tochar()}
- {@link LuaValue#toshort()}
- {@link LuaValue#toint()}
- {@link LuaValue#tofloat()}
- {@link LuaValue#todouble()}
- {@link LuaValue#tojstring()}
- {@link LuaValue#touserdata()}
- {@link LuaValue#touserdata(Class)}
For data in lua tables, the various methods on {@link LuaTable} can be used directly to convert data to something more useful.
@see LuajavaLib
@see CoerceJavaToLua