Pioneer
Loading...
Searching...
No Matches
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)
 
static void RegisterSerializer (const char *type, SerializerPair pair)
 
static bool SerializeComponents (LuaWrappable *object, Json &out)
 
static bool DeserializeComponents (LuaWrappable *object, const Json &obj)
 
static void DeregisterObject (LuaWrappable *object)
 

Protected Member Functions

 LuaObjectBase (const char *type)
 
virtual ~LuaObjectBase ()
 
virtual LuaWrappableGetObject () const =0
 
virtual void ClearObject ()
 
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 RegisterPersistent (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 bool SerializeToJson (lua_State *l, Json &out)
 
static bool DeserializeFromJson (lua_State *l, const Json &obj)
 
static void * Allocate (size_t n)
 
template<typename T >
static T * Allocate ()
 
template<typename T , typename... Args>
static T * AllocateNew (Args &&...args)
 

Friends

class LuaSerializer
 
class LuaObjectHelpers
 

Constructor & Destructor Documentation

◆ LuaObjectBase()

LuaObjectBase::LuaObjectBase ( const char *  type)
inlineprotected

◆ ~LuaObjectBase()

virtual LuaObjectBase::~LuaObjectBase ( )
inlineprotectedvirtual

Member Function Documentation

◆ Allocate() [1/2]

template<typename T >
static T * LuaObjectBase::Allocate ( )
inlinestaticprotected
Here is the call graph for this function:

◆ Allocate() [2/2]

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

◆ AllocateNew()

template<typename T , typename... Args>
static T * LuaObjectBase::AllocateNew ( Args &&...  args)
inlinestaticprotected

◆ CheckFromLua()

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

◆ ClearObject()

virtual void LuaObjectBase::ClearObject ( )
inlineprotectedvirtual

◆ 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:

◆ DeregisterObject()

void LuaObjectBase::DeregisterObject ( LuaWrappable object)
static
Here is the call graph for this function:

◆ DeserializeComponents()

bool LuaObjectBase::DeserializeComponents ( LuaWrappable object,
const Json obj 
)
static
Here is the call graph for this function:

◆ DeserializeFromJson()

bool LuaObjectBase::DeserializeFromJson ( lua_State *  l,
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

◆ 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:

◆ RegisterPersistent()

void LuaObjectBase::RegisterPersistent ( 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 
)
static
Here is the call graph for this function:

◆ SerializeComponents()

bool LuaObjectBase::SerializeComponents ( LuaWrappable object,
Json out 
)
static
Here is the call graph for this function:

◆ SerializeToJson()

bool LuaObjectBase::SerializeToJson ( lua_State *  l,
Json out 
)
staticprotected

Friends And Related Symbol Documentation

◆ LuaObjectHelpers

friend class LuaObjectHelpers
friend

◆ LuaSerializer

friend class LuaSerializer
friend

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