CL_Lua3
Cl_lua class
Overview
Binds global functions of Lua API. Refer to Lua manual for details.
Class members
- static int
dofile( -
char *filename)
- static int
dostring( -
char *string)
- static void
error( -
char* message)
- static CL_LuaObject
getparam( -
int number)
- static CL_LuaObject
getresult( -
int number)
- static CL_LuaObject
getglobal( -
char* var)
- static CL_LuaObject
setfallback( -
char* name, lua_CFunction fallback)
- static void
record( -
char* name, lua_CFunction func)
- static CL_LuaObject
createObject( -
lua_Object lo)
- static void
iolibopen( -
void)
- static void
strlibopen( -
void)
- static void
mathlibopen( -
void)
- static void
dblibopen( -
void)
Members with descriptions
- static int
dofile( -
char *filename)
Parameters: filename - the script file name
Description:
Execute a Lua chunk stored in a file
Return value:
the return code
- static int
dostring( -
char *string)
Parameters: string - the lua string
Description:
Execute a Lua chunk stored in a string
Return value:
the return code
- static void
error( -
char* message)
Parameters: message - the error message
Description:
Generate a Lua error, with the given message
- static CL_LuaObject
getparam( -
int number)
Parameters: number: the number
Description:
Get a parameter from Lua stack
Return value:
the return code
- static CL_LuaObject
getresult( -
int number)
Parameters: number: the number
Description:
Get a result from Lua stack
Return value:
the return code
- static CL_LuaObject
getglobal( -
char* var)
Parameters: var: the name of the global variable
Description:
Get a Lua global variable
Return value:
the return code
- static CL_LuaObject
setfallback( -
char* name, lua_CFunction fallback)
Parameters: name - the name of the fallback fallback - pointer to the function
Description:
Set Lua fallback
Return value:
the return code
- static void
record( -
char* name, lua_CFunction func)
Parameters: name - the name of the function func - pointer to the function
Description:
Register a C++ function to be called from Lua
- static CL_LuaObject
createObject( -
lua_Object lo)
Parameters: obj - the object
Description:
Create a LuaObject from a lua_Object
Return value:
the return code
- static void
iolibopen( -
void)
Description:
Open the IO library
- static void
strlibopen( -
void)
Description:
Open the string library
- static void
mathlibopen( -
void)
Description:
Open the math library
- static void
dblibopen( -
void)
Description:
Open the db library