Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

LuaState.h File Reference

#include <stdarg.h>
#include <wchar.h>
#include <assert.h>
#include "Lua.h"
#include "luadebug.h"
#include "lauxlib.h"

Go to the source code of this file.

Compounds

class  LuaAutoBlock
class  LuaObject
class  LuaState
struct  lua_Debug
struct  luaL_Buffer
struct  luaL_reg
struct  luaState_reg
class  LuaStateOutFile
class  LuaStateOwner

Defines

#define LUA_PRIVATE

Typedefs

typedef void *(* lua_ReallocFunction )(void *ptr, int size, void *data, const char *allocName, unsigned int flags)
typedef void(* lua_FreeFunction )(void *ptr, void *data)
typedef lua_State lua_State
typedef int(* lua_CFunction )(lua_State *L)
typedef LUA_NUMBER lua_Number
typedef L_CHAR lua_char
typedef lua_Debug lua_Debug
typedef lua_Localvar lua_Localvar
typedef void(* lua_Hook )(lua_State *L, lua_Debug *ar)
typedef luaL_reg luaL_reg
typedef luaL_Buffer luaL_Buffer
typedef lua_CFunction LuaCFunction
typedef int(* LuaStateCFunction )(LuaState state)
typedef luaState_reg LuaFunctionList

Functions

void lua_getdefaultmemoryfunctions (lua_ReallocFunction *reallocFunc, lua_FreeFunction *freeFunc, void **data)
void lua_setdefaultmemoryfunctions (lua_ReallocFunction reallocFunc, lua_FreeFunction freeFunc, void *data)
LUA_API void lua_setlockfunctions (lua_State *L, void(*lockFunc)(void *), void(*unlockFunc)(void *), void *lockData)
LUA_API void lua_setfatalerrorfunction (lua_State *L, void(*fatalErrorFunc)())
LUA_API void lua_setminimumstringtablesize (int numstrings)
LUA_API void lua_setdefaulttagtablesize (int numtags)
LUA_API void lua_setminimumglobaltablesize (int numentries)
LUA_API unsigned int lua_setmainfunctionallocflags (lua_State *L, unsigned int allocFlags)
LUA_API void lua_setminimumauxspace (int size)
LUA_API void lua_getmethods (lua_State *L, int index)
LUA_API void lua_getdefaultmethods (lua_State *L, int type)
LUA_API void lua_setmethods (lua_State *L, int index)
LUA_API void lua_pushpointer (lua_State *L, const void *ptr)
LUA_API int lua_ispointer (lua_State *L, int index)
LUA_API const void * lua_getpointer (lua_State *L, int index)
LUA_API lua_Statelua_newthread (lua_State *L, int stacksize)
LUA_API void lua_close (lua_State *L)
__inline int lua_gettop (lua_State *L)
LUA_API void lua_settop (lua_State *L, int index)
LUA_API void lua_pushvalue (lua_State *L, int index)
LUA_API void lua_remove (lua_State *L, int index)
LUA_API void lua_insert (lua_State *L, int index)
LUA_API int lua_stackspace (lua_State *L)
LUA_API const lua_charlua_type (lua_State *L, int index)
LUA_API int lua_isnumber (lua_State *L, int index)
LUA_API int lua_isstring (lua_State *L, int index)
LUA_API int lua_isustring (lua_State *L, int index)
LUA_API int lua_iscfunction (lua_State *L, int index)
LUA_API int lua_tag (lua_State *L, int index)
LUA_API int lua_rawtag (lua_State *L, int index)
LUA_API int lua_equal (lua_State *L, int index1, int index2)
LUA_API int lua_lessthan (lua_State *L, int index1, int index2)
LUA_API lua_Number lua_tonumber (lua_State *L, int index)
LUA_API const lua_charlua_tostring (lua_State *L, int index)
LUA_API const wchar_t * lua_toustring (lua_State *L, int index)
LUA_API size_t lua_strlen (lua_State *L, int index)
LUA_API lua_CFunction lua_tocfunction (lua_State *L, int index)
LUA_API void * lua_touserdata (lua_State *L, int index)
LUA_API const void * lua_topointer (lua_State *L, int index)
LUA_API void lua_pushnil (lua_State *L)
LUA_API void lua_pushnumber (lua_State *L, lua_Number n)
LUA_API void lua_pushlstring (lua_State *L, const lua_char *s, size_t len)
LUA_API void lua_pushlustring (lua_State *L, const wchar_t *s, size_t len)
LUA_API void lua_pushstring (lua_State *L, const lua_char *s)
LUA_API void lua_pushustring (lua_State *L, const wchar_t *s)
LUA_API void lua_pushcclosure (lua_State *L, lua_CFunction fn, int n)
LUA_API void lua_getglobal (lua_State *L, const lua_char *name)
LUA_API void lua_gettable (lua_State *L, int index)
LUA_API void lua_rawget (lua_State *L, int index)
LUA_API void lua_rawgeti (lua_State *L, int index, int n)
LUA_API void lua_getglobals (lua_State *L)
LUA_API void lua_gettagmethod (lua_State *L, int tag, const lua_char *event)
LUA_API int lua_getref (lua_State *L, int ref)
LUA_API void lua_newtable (lua_State *L)
LUA_API void lua_newtablesize (lua_State *L, int size)
LUA_API void lua_getregistry (lua_State *L)
LUA_API void lua_getweakregistry (lua_State *L)
LUA_API void lua_setglobal (lua_State *L, const lua_char *name)
LUA_API void lua_settable (lua_State *L, int index)
LUA_API void lua_rawset (lua_State *L, int index)
LUA_API void lua_rawseti (lua_State *L, int index, int n)
LUA_API void lua_setglobals (lua_State *L)
LUA_API void lua_settagmethod (lua_State *L, int tag, const lua_char *event)
LUA_API int lua_ref (lua_State *L, int lock)
LUA_API int lua_call (lua_State *L, int nargs, int nresults)
LUA_API void lua_rawcall (lua_State *L, int nargs, int nresults)
LUA_API int lua_loadfile (lua_State *L, const lua_char *filename)
LUA_API int lua_dofile (lua_State *L, const lua_char *filename)
LUA_API int lua_dostring (lua_State *L, const lua_char *str)
LUA_API int lua_loadbuffer (lua_State *L, const lua_char *buff, size_t size, const lua_char *name)
LUA_API int lua_dobuffer (lua_State *L, const lua_char *buff, size_t size, const lua_char *name)
LUA_API int lua_getgcthreshold (lua_State *L)
LUA_API int lua_getgccount (lua_State *L)
LUA_API void lua_setgcthreshold (lua_State *L, int newthreshold)
LUA_API int lua_newtype (lua_State *L, const lua_char *name, int basictype)
LUA_API int lua_copytagmethods (lua_State *L, int tagto, int tagfrom)
LUA_API void lua_settag (lua_State *L, int tag)
LUA_API int lua_name2tag (lua_State *L, const lua_char *name)
LUA_API const lua_charlua_tag2name (lua_State *L, int tag)
LUA_API void lua_error (lua_State *L, const lua_char *s)
LUA_API void lua_unref (lua_State *L, int ref)
LUA_API int lua_next (lua_State *L, int index)
LUA_API int lua_getn (lua_State *L, int index)
LUA_API void lua_concat (lua_State *L, int n)
LUA_API void * lua_newuserdata (lua_State *L, size_t size)
LUA_API void lua_newuserdatabox (lua_State *L, void *u)
LUA_API void lua_setweakmode (lua_State *L, int mode)
LUA_API int lua_getweakmode (lua_State *L, int index)
LUA_API int lua_getstack (lua_State *L, int level, lua_Debug *ar)
LUA_API int lua_getinfo (lua_State *L, const lua_char *what, lua_Debug *ar)
LUA_API const lua_charlua_getlocal (lua_State *L, const lua_Debug *ar, int n)
LUA_API const lua_charlua_setlocal (lua_State *L, const lua_Debug *ar, int n)
LUA_API lua_Hook lua_setcallhook (lua_State *L, lua_Hook func)
LUA_API lua_Hook lua_setlinehook (lua_State *L, lua_Hook func)
LUALIB_API void luaL_openlib (lua_State *L, const luaL_reg *l, int n)
LUALIB_API void luaL_openlibintotable (lua_State *L, const luaL_reg *l, int n)
LUALIB_API void luaL_argerror (lua_State *L, int numarg, const lua_char *extramsg)
LUALIB_API const lua_charluaL_check_lstr (lua_State *L, int numArg, size_t *len)
LUALIB_API const wchar_t * luaL_check_lustr (lua_State *L, int numArg, size_t *len)
LUALIB_API const lua_charluaL_opt_lstr (lua_State *L, int numArg, const lua_char *def, size_t *len)
LUALIB_API lua_Number luaL_check_number (lua_State *L, int numArg)
LUALIB_API lua_Number luaL_opt_number (lua_State *L, int nArg, lua_Number def)
LUALIB_API void luaL_checkstack (lua_State *L, int space, const lua_char *msg)
LUALIB_API void luaL_checktype (lua_State *L, int narg, int t)
LUALIB_API void luaL_checkany (lua_State *L, int narg)
LUALIB_API void * luaL_check_userdata (lua_State *L, int narg, const lua_char *name)
LUALIB_API void luaL_verror (lua_State *L, const lua_char *fmt,...)
LUALIB_API int luaL_findstring (const lua_char *name, const lua_char *const list[])
LUALIB_API void luaL_buffinit (lua_State *L, luaL_Buffer *B, int isUnicode)
LUALIB_API lua_charluaL_prepbuffer (luaL_Buffer *B)
LUALIB_API void luaL_addlstring (luaL_Buffer *B, const lua_char *s, size_t l)
LUALIB_API void luaL_addlustring (luaL_Buffer *B, const wchar_t *s, size_t l)
LUALIB_API void luaL_addstring (luaL_Buffer *B, const lua_char *s)
LUALIB_API void luaL_addustring (luaL_Buffer *B, const wchar_t *s)
LUALIB_API void luaL_addvalue (luaL_Buffer *B)
LUALIB_API void luaL_pushresult (luaL_Buffer *B)


Define Documentation

#define LUA_PRIVATE
 

Definition at line 18 of file LuaState.h.


Typedef Documentation

typedef lua_CFunction LuaCFunction
 

Definition at line 598 of file LuaState.h.

typedef luaState_reg LuaFunctionList
 

Definition at line 615 of file LuaState.h.

typedef int(* LuaStateCFunction)(LuaState state)
 

Definition at line 599 of file LuaState.h.

typedef struct luaL_Buffer luaL_Buffer
 

typedef struct luaL_reg luaL_reg
 

typedef int(* lua_CFunction)(lua_State *L)
 

Definition at line 89 of file LuaState.h.

typedef struct lua_Debug lua_Debug
 

Definition at line 440 of file LuaState.h.

typedef void(* lua_FreeFunction)(void* ptr, void* data)
 

Definition at line 52 of file LuaState.h.

typedef void(* lua_Hook)(lua_State *L, lua_Debug *ar)
 

Definition at line 443 of file LuaState.h.

typedef struct lua_Localvar lua_Localvar
 

Definition at line 441 of file LuaState.h.

typedef LUA_NUMBER lua_Number
 

Definition at line 128 of file LuaState.h.

typedef void*(* lua_ReallocFunction)(void* ptr, int size, void* data, const char* allocName, unsigned int flags)
 

Definition at line 51 of file LuaState.h.

typedef struct lua_State lua_State
 

Definition at line 87 of file LuaState.h.

typedef L_CHAR lua_char
 

Definition at line 134 of file LuaState.h.


Function Documentation

LUALIB_API void luaL_addlstring luaL_Buffer   B,
const lua_char   s,
size_t    l
 

LUALIB_API void luaL_addlustring luaL_Buffer   B,
const wchar_t *    s,
size_t    l
 

LUALIB_API void luaL_addstring luaL_Buffer   B,
const lua_char   s
 

LUALIB_API void luaL_addustring luaL_Buffer   B,
const wchar_t *    s
 

LUALIB_API void luaL_addvalue luaL_Buffer   B
 

LUALIB_API void luaL_argerror lua_State   L,
int    numarg,
const lua_char   extramsg
 

LUALIB_API void luaL_buffinit lua_State   L,
luaL_Buffer   B,
int    isUnicode
 

LUALIB_API const lua_char* luaL_check_lstr lua_State   L,
int    numArg,
size_t *    len
 

LUALIB_API const wchar_t* luaL_check_lustr lua_State   L,
int    numArg,
size_t *    len
 

LUALIB_API lua_Number luaL_check_number lua_State   L,
int    numArg
 

LUALIB_API void* luaL_check_userdata lua_State   L,
int    narg,
const lua_char   name
 

LUALIB_API void luaL_checkany lua_State   L,
int    narg
 

LUALIB_API void luaL_checkstack lua_State   L,
int    space,
const lua_char   msg
 

LUALIB_API void luaL_checktype lua_State   L,
int    narg,
int    t
 

LUALIB_API int luaL_findstring const lua_char   name,
const lua_char *const    list[]
 

LUALIB_API void luaL_openlib lua_State   L,
const luaL_reg   l,
int    n
 

LUALIB_API void luaL_openlibintotable lua_State   L,
const luaL_reg   l,
int    n
 

LUALIB_API const lua_char* luaL_opt_lstr lua_State   L,
int    numArg,
const lua_char   def,
size_t *    len
 

LUALIB_API lua_Number luaL_opt_number lua_State   L,
int    nArg,
lua_Number    def
 

LUALIB_API lua_char* luaL_prepbuffer luaL_Buffer   B
 

LUALIB_API void luaL_pushresult luaL_Buffer   B
 

LUALIB_API void luaL_verror lua_State   L,
const lua_char   fmt,
...   
 

LUA_API int lua_call lua_State   L,
int    nargs,
int    nresults
 

Referenced by luaL_Buffer::buffer().

LUA_API void lua_close lua_State   L
 

Referenced by LuaObject::SetNil().

LUA_API void lua_concat lua_State   L,
int    n
 

Referenced by LuaCFunction().

LUA_API int lua_copytagmethods lua_State   L,
int    tagto,
int    tagfrom
 

LUA_API int lua_dobuffer lua_State   L,
const lua_char   buff,
size_t    size,
const lua_char   name
 

Referenced by luaL_addusize().

LUA_API int lua_dofile lua_State   L,
const lua_char   filename
 

LUA_API int lua_dostring lua_State   L,
const lua_char   str
 

LUA_API int lua_equal lua_State   L,
int    index1,
int    index2
 

LUA_API void lua_error lua_State   L,
const lua_char   s
 

void lua_getdefaultmemoryfunctions lua_ReallocFunction   reallocFunc,
lua_FreeFunction   freeFunc,
void **    data
 

LUA_API void lua_getdefaultmethods lua_State   L,
int    type
 

LUA_API int lua_getgccount lua_State   L
 

LUA_API int lua_getgcthreshold lua_State   L
 

LUA_API void lua_getglobal lua_State   L,
const lua_char   name
 

Referenced by luaL_openlintotable().

LUA_API void lua_getglobals lua_State   L
 

LUA_API int lua_getinfo lua_State   L,
const lua_char   what,
lua_Debug   ar
 

LUA_API const lua_char* lua_getlocal lua_State   L,
const lua_Debug   ar,
int    n
 

LUA_API void lua_getmethods lua_State   L,
int    index
 

LUA_API int lua_getn lua_State   L,
int    index
 

LUA_API const void* lua_getpointer lua_State   L,
int    index
 

Referenced by lua_char().

LUA_API int lua_getref lua_State   L,
int    ref
 

LUA_API void lua_getregistry lua_State   L
 

LUA_API int lua_getstack lua_State   L,
int    level,
lua_Debug   ar
 

LUA_API void lua_gettable lua_State   L,
int    index
 

LUA_API void lua_gettagmethod lua_State   L,
int    tag,
const lua_char   event
 

__inline int lua_gettop lua_State   L
 

Definition at line 171 of file LuaState.h.

Referenced by LuaObject::CreateTable(), LUALIB_API(), and lua_ustr2number().

00172     {
00173         lua_newtablesize(m_state, size);                    // T

LUA_API int lua_getweakmode lua_State   L,
int    index
 

LUA_API void lua_getweakregistry lua_State   L
 

LUA_API void lua_insert lua_State   L,
int    index
 

LUA_API int lua_iscfunction lua_State   L,
int    index
 

Referenced by LUA_TUSTRING().

LUA_API int lua_isnumber lua_State   L,
int    index
 

LUA_API int lua_ispointer lua_State   L,
int    index
 

LUA_API int lua_isstring lua_State   L,
int    index
 

Referenced by LUA_NTYPES().

LUA_API int lua_isustring lua_State   L,
int    index
 

Referenced by LUA_NTYPES().

LUA_API int lua_lessthan lua_State   L,
int    index1,
int    index2
 

LUA_API int lua_loadbuffer lua_State   L,
const lua_char   buff,
size_t    size,
const lua_char   name
 

Referenced by luaL_putwchar().

LUA_API int lua_loadfile lua_State   L,
const lua_char   filename
 

Referenced by luaL_putchar().

LUA_API int lua_name2tag lua_State   L,
const lua_char   name
 

LUA_API void lua_newtable lua_State   L
 

LUA_API void lua_newtablesize lua_State   L,
int    size
 

Referenced by lua_gettop().

LUA_API lua_State* lua_newthread lua_State   L,
int    stacksize
 

Referenced by LSUnlock().

LUA_API int lua_newtype lua_State   L,
const lua_char   name,
int    basictype
 

LUA_API void* lua_newuserdata lua_State   L,
size_t    size
 

LUA_API void lua_newuserdatabox lua_State   L,
void *    u
 

LUA_API int lua_next lua_State   L,
int    index
 

LUA_API void lua_pushcclosure lua_State   L,
lua_CFunction    fn,
int    n
 

Referenced by LuaObject::LuaObject(), luaL_check_int(), and luaL_check_long().

LUA_API void lua_pushlstring lua_State   L,
const lua_char   s,
size_t    len
 

LUA_API void lua_pushlustring lua_State   L,
const wchar_t *    s,
size_t    len
 

Referenced by luaL_check_ustring().

LUA_API void lua_pushnil lua_State   L
 

LUA_API void lua_pushnumber lua_State   L,
lua_Number    n
 

Referenced by l_c(), luaL_arg_check(), and lua_gettop().

LUA_API void lua_pushpointer lua_State   L,
const void *    ptr
 

Referenced by luaL_opt_int(), and lua_pushuliteral().

LUA_API void lua_pushstring lua_State   L,
const lua_char   s
 

Referenced by l_us(), luaL_check_string(), and lua_pushuliteral().

LUA_API void lua_pushustring lua_State   L,
const wchar_t *    s
 

Referenced by luaL_opt_string().

LUA_API void lua_pushvalue lua_State   L,
int    index
 

Referenced by l_c(), l_us(), lua_gettop(), and luaL_reg::name().

LUA_API void lua_rawcall lua_State   L,
int    nargs,
int    nresults
 

LUA_API void lua_rawget lua_State   L,
int    index
 

LUA_API void lua_rawgeti lua_State   L,
int    index,
int    n
 

Referenced by lua_ustr2number().

LUA_API void lua_rawset lua_State   L,
int    index
 

LUA_API void lua_rawseti lua_State   L,
int    index,
int    n
 

LUA_API int lua_rawtag lua_State   L,
int    index
 

Referenced by LUA_TNIL(), and LUA_TPOINTER().

LUA_API int lua_ref lua_State   L,
int    lock
 

Referenced by luaL_Buffer::isUnicode().

LUA_API void lua_remove lua_State   L,
int    index
 

Referenced by luaL_reg::func().

LUA_API lua_Hook lua_setcallhook lua_State   L,
lua_Hook    func
 

void lua_setdefaultmemoryfunctions lua_ReallocFunction    reallocFunc,
lua_FreeFunction    freeFunc,
void *    data
 

LUA_API void lua_setdefaulttagtablesize int    numtags
 

LUA_API void lua_setfatalerrorfunction lua_State   L,
void(*    fatalErrorFunc)()
 

LUA_API void lua_setgcthreshold lua_State   L,
int    newthreshold
 

LUA_API void lua_setglobal lua_State   L,
const lua_char   name
 

Referenced by LUAL_BUFFERSIZE().

LUA_API void lua_setglobals lua_State   L
 

Referenced by luaL_Buffer::p().

LUA_API lua_Hook lua_setlinehook lua_State   L,
lua_Hook    func
 

LUA_API const lua_char* lua_setlocal lua_State   L,
const lua_Debug   ar,
int    n
 

LUA_API void lua_setlockfunctions lua_State   L,
void(*    lockFunc)(void *),
void(*    unlockFunc)(void *),
void *    lockData
 

LUA_API unsigned int lua_setmainfunctionallocflags lua_State   L,
unsigned int    allocFlags
 

LUA_API void lua_setmethods lua_State   L,
int    index
 

LUA_API void lua_setminimumauxspace int    size
 

LUA_API void lua_setminimumglobaltablesize int    numentries
 

LUA_API void lua_setminimumstringtablesize int    numstrings
 

LUA_API void lua_settable lua_State   L,
int    index
 

Referenced by l_us(), lua_gettop(), and lua_pushuliteral().

LUA_API void lua_settag lua_State   L,
int    tag
 

LUA_API void lua_settagmethod lua_State   L,
int    tag,
const lua_char   event
 

Referenced by luaL_Buffer::level().

LUA_API void lua_settop lua_State   L,
int    index
 

LUA_API void lua_setweakmode lua_State   L,
int    mode
 

LUA_API int lua_stackspace lua_State   L
 

LUA_API size_t lua_strlen lua_State   L,
int    index
 

Referenced by lua_Number().

LUA_API int lua_tag lua_State   L,
int    index
 

LUA_API const lua_char* lua_tag2name lua_State   L,
int    tag
 

LUA_API lua_CFunction lua_tocfunction lua_State   L,
int    index
 

LUA_API lua_Number lua_tonumber lua_State   L,
int    index
 

LUA_API const void* lua_topointer lua_State   L,
int    index
 

LUA_API const lua_char* lua_tostring lua_State   L,
int    index
 

LUA_API void* lua_touserdata lua_State   L,
int    index
 

Referenced by L_CHAR().

LUA_API const wchar_t* lua_toustring lua_State   L,
int    index
 

LUA_API const lua_char* lua_type lua_State   L,
int    index
 

Referenced by LUA_TUSERDATA().

LUA_API void lua_unref lua_State   L,
int    ref
 


Generated on Wed Nov 7 21:15:16 2001 for LuaState(LuaWrapper) by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001