Code::Blocks  SVN r11506
Macros | Functions
sqobject.cpp File Reference
#include "sqpcheader.h"
#include "sqvm.h"
#include "sqstring.h"
#include "sqarray.h"
#include "sqtable.h"
#include "squserdata.h"
#include "sqfuncproto.h"
#include "sqclass.h"
#include "sqclosure.h"
Include dependency graph for sqobject.cpp:

Go to the source code of this file.

Macros

#define _CHECK_IO(exp)   { if(!exp)return false; }
 
#define START_MARK()
 
#define END_MARK()
 

Functions

const SQCharIdType2Name (SQObjectType type)
 
const SQCharGetTypeName (const SQObjectPtr &obj1)
 
SQUnsignedInteger TranslateIndex (const SQObjectPtr &idx)
 
bool SafeWrite (HSQUIRRELVM v, SQWRITEFUNC write, SQUserPointer up, SQUserPointer dest, SQInteger size)
 
bool SafeRead (HSQUIRRELVM v, SQWRITEFUNC read, SQUserPointer up, SQUserPointer dest, SQInteger size)
 
bool WriteTag (HSQUIRRELVM v, SQWRITEFUNC write, SQUserPointer up, SQInteger tag)
 
bool CheckTag (HSQUIRRELVM v, SQWRITEFUNC read, SQUserPointer up, SQInteger tag)
 
bool WriteObject (HSQUIRRELVM v, SQUserPointer up, SQWRITEFUNC write, SQObjectPtr &o)
 
bool ReadObject (HSQUIRRELVM v, SQUserPointer up, SQREADFUNC read, SQObjectPtr &o)
 

Macro Definition Documentation

◆ _CHECK_IO

#define _CHECK_IO (   exp)    { if(!exp)return false; }

Definition at line 231 of file sqobject.cpp.

Referenced by CheckTag(), ReadObject(), and WriteObject().

◆ END_MARK

#define END_MARK ( )
Value:
RemoveFromChain(&_sharedstate->_gc_chain, this); \
AddToChain(chain, this); }

Definition at line 488 of file sqobject.cpp.

◆ START_MARK

#define START_MARK ( )
Value:
if(!(_uiRef&MARK_FLAG)){ \
_uiRef|=MARK_FLAG;

Definition at line 485 of file sqobject.cpp.

Function Documentation

◆ CheckTag()

bool CheckTag ( HSQUIRRELVM  v,
SQWRITEFUNC  read,
SQUserPointer  up,
SQInteger  tag 
)

Definition at line 255 of file sqobject.cpp.

References _CHECK_IO, and SafeRead().

Referenced by ReadObject().

◆ GetTypeName()

const SQChar* GetTypeName ( const SQObjectPtr &  obj1)

◆ IdType2Name()

const SQChar* IdType2Name ( SQObjectType  type)

Definition at line 15 of file sqobject.cpp.

References NULL.

Referenced by GetTypeName(), ReadObject(), sq_aux_gettypedarg(), sq_aux_invalidtype(), and sq_stackinfos().

◆ ReadObject()

bool ReadObject ( HSQUIRRELVM  v,
SQUserPointer  up,
SQREADFUNC  read,
SQObjectPtr &  o 
)

◆ SafeRead()

bool SafeRead ( HSQUIRRELVM  v,
SQWRITEFUNC  read,
SQUserPointer  up,
SQUserPointer  dest,
SQInteger  size 
)

Definition at line 241 of file sqobject.cpp.

Referenced by CheckTag(), and ReadObject().

◆ SafeWrite()

bool SafeWrite ( HSQUIRRELVM  v,
SQWRITEFUNC  write,
SQUserPointer  up,
SQUserPointer  dest,
SQInteger  size 
)

Definition at line 232 of file sqobject.cpp.

Referenced by ReadObject(), WriteObject(), and WriteTag().

◆ TranslateIndex()

SQUnsignedInteger TranslateIndex ( const SQObjectPtr &  idx)

Definition at line 73 of file sqobject.cpp.

References _null_, and NULL.

Referenced by GetTypeName().

◆ WriteObject()

bool WriteObject ( HSQUIRRELVM  v,
SQUserPointer  up,
SQWRITEFUNC  write,
SQObjectPtr &  o 
)

Definition at line 266 of file sqobject.cpp.

References _CHECK_IO, GetTypeName(), and SafeWrite().

Referenced by ReadObject().

◆ WriteTag()

bool WriteTag ( HSQUIRRELVM  v,
SQWRITEFUNC  write,
SQUserPointer  up,
SQInteger  tag 
)

Definition at line 250 of file sqobject.cpp.

References SafeWrite().

Referenced by ReadObject().