Pioneer
Static Public Member Functions | Protected Member Functions | Static Protected Member Functions | Friends | List of all members
LuaObjectBase Class Referenceabstract

#include <LuaObject.h>

Inheritance diagram for LuaObjectBase:
Inheritance graph
[legend]

Static Public Member Functions

static void CreateObject (const luaL_Reg *methods, const luaL_Reg *attrs, const luaL_Reg *meta, bool protect=false)
 
static void CreateObject (LuaMetaTypeBase *metaType)
 
static PropertyMapGetPropertiesFromObject (lua_State *l, int object)
 

Protected Member Functions

 LuaObjectBase (const char *type)
 
virtual ~LuaObjectBase ()
 
std::string Serialize ()
 
void ToJson (Json &out)
 
virtual LuaWrappableGetObject () const =0
 
const char * GetType () const
 

Static Protected Member Functions

static void CreateClass (const char *type, const char *parent, const luaL_Reg *methods, const luaL_Reg *attrs, const luaL_Reg *meta)
 
static void CreateClass (LuaMetaTypeBase *metaType)
 
static bool PushRegistered (LuaWrappable *o)
 
static void Register (LuaObjectBase *lo)
 
static void Deregister (LuaObjectBase *lo)
 
static LuaWrappableCheckFromLua (int index, const char *type)
 
static LuaWrappableGetFromLua (int index, const char *type)
 
static void RegisterPromotion (const char *base_type, const char *target_type, PromotionTest test_fn)
 
static void RegisterSerializer (const char *type, SerializerPair pair)
 
static bool Deserialize (const char *stream, const char **next)
 
static bool FromJson (const Json &obj)
 
static void * Allocate (size_t n)
 

Friends

class LuaSerializer
 
class LuaObjectHelpers
 

Constructor & Destructor Documentation

◆ LuaObjectBase()

LuaObjectBase::LuaObjectBase ( const char *  type)
inlineprotected

◆ ~LuaObjectBase()

virtual LuaObjectBase::~LuaObjectBase ( )
inlineprotectedvirtual

Member Function Documentation

◆ Allocate()

void * LuaObjectBase::Allocate ( size_t  n)
staticprotected
Here is the call graph for this function:

◆ CheckFromLua()

LuaWrappable * LuaObjectBase::CheckFromLua ( int  index,
const char *  type 
)
staticprotected
Here is the call graph for this function:

◆ CreateClass() [1/2]

void LuaObjectBase::CreateClass ( const char *  type,
const char *  parent,
const luaL_Reg *  methods,
const luaL_Reg *  attrs,
const luaL_Reg *  meta 
)
staticprotected
Here is the call graph for this function:

◆ CreateClass() [2/2]

void LuaObjectBase::CreateClass ( LuaMetaTypeBase metaType)
staticprotected
Here is the call graph for this function:

◆ CreateObject() [1/2]

void LuaObjectBase::CreateObject ( const luaL_Reg *  methods,
const luaL_Reg *  attrs,
const luaL_Reg *  meta,
bool  protect = false 
)
static
Here is the call graph for this function:

◆ CreateObject() [2/2]

void LuaObjectBase::CreateObject ( LuaMetaTypeBase metaType)
static
Here is the call graph for this function:

◆ Deregister()

void LuaObjectBase::Deregister ( LuaObjectBase lo)
staticprotected
Here is the call graph for this function:

◆ Deserialize()

bool LuaObjectBase::Deserialize ( const char *  stream,
const char **  next 
)
staticprotected
Here is the call graph for this function:

◆ FromJson()

bool LuaObjectBase::FromJson ( const Json obj)
staticprotected

◆ GetFromLua()

LuaWrappable * LuaObjectBase::GetFromLua ( int  index,
const char *  type 
)
staticprotected
Here is the call graph for this function:

◆ GetObject()

virtual LuaWrappable* LuaObjectBase::GetObject ( ) const
protectedpure virtual

◆ GetPropertiesFromObject()

PropertyMap * LuaObjectBase::GetPropertiesFromObject ( lua_State *  l,
int  object 
)
static
Here is the call graph for this function:

◆ GetType()

const char* LuaObjectBase::GetType ( ) const
inlineprotected

◆ PushRegistered()

bool LuaObjectBase::PushRegistered ( LuaWrappable o)
staticprotected
Here is the call graph for this function:

◆ Register()

void LuaObjectBase::Register ( LuaObjectBase lo)
staticprotected
Here is the call graph for this function:

◆ RegisterPromotion()

void LuaObjectBase::RegisterPromotion ( const char *  base_type,
const char *  target_type,
PromotionTest  test_fn 
)
staticprotected

◆ RegisterSerializer()

void LuaObjectBase::RegisterSerializer ( const char *  type,
SerializerPair  pair 
)
staticprotected

◆ Serialize()

std::string LuaObjectBase::Serialize ( )
protected
Here is the call graph for this function:

◆ ToJson()

void LuaObjectBase::ToJson ( Json out)
protected
Here is the call graph for this function:

Friends And Related Function Documentation

◆ LuaObjectHelpers

friend class LuaObjectHelpers
friend

◆ LuaSerializer

friend class LuaSerializer
friend

The documentation for this class was generated from the following files: