HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
GA_PrimitiveJSONExtend Class Referenceabstract

Class which extends an existing JSON schema. More...

#include <GA_PrimitiveJSONExtend.h>

+ Inheritance diagram for GA_PrimitiveJSONExtend:

Public Member Functions

 GA_PrimitiveJSONExtend (const GA_PrimitiveJSON *base)
 
virtual ~GA_PrimitiveJSONExtend ()
 
virtual int getEntries () const
 
virtual const UT_StringHoldergetKeyword (int i) const
 
virtual bool saveField (const GA_Primitive *prim, int i, UT_JSONWriter &w, const GA_SaveMap &map) const
 
virtual bool saveField (const GA_Primitive *prim, int i, UT_JSONValue &value, const GA_SaveMap &map) const
 
virtual bool loadField (GA_Primitive *prim, int i, UT_JSONParser &p, const GA_LoadMap &map) const
 
virtual bool loadField (GA_Primitive *prim, int i, UT_JSONParser &p, const UT_JSONValue &value, const GA_LoadMap &map) const
 
virtual bool isEqual (int i, const GA_Primitive *prim1, const GA_Primitive *prim2) const
 
virtual int localEntries () const =0
 
virtual const UT_StringHolderlocalKeyword (int i) const =0
 
virtual bool localSave (const GA_Primitive *prim, int i, UT_JSONWriter &w, const GA_SaveMap &map) const =0
 
virtual bool localSave (const GA_Primitive *prim, int i, UT_JSONValue &value, const GA_SaveMap &map) const =0
 
virtual bool localLoad (GA_Primitive *prim, int i, UT_JSONParser &p, const GA_LoadMap &map) const =0
 
virtual bool localLoad (GA_Primitive *prim, int i, UT_JSONParser &p, const UT_JSONValue &value, const GA_LoadMap &map) const =0
 
virtual bool localIsEqual (int i, const GA_Primitive *prim1, const GA_Primitive *prim2) const =0
 
- Public Member Functions inherited from GA_PrimitiveJSON
 GA_PrimitiveJSON ()
 
virtual ~GA_PrimitiveJSON ()
 
virtual bool shouldSaveField (const GA_Primitive *prim, int i, const GA_SaveMap &save) const
 
virtual bool save (const GA_Primitive *prim, UT_JSONWriter &w, const GA_SaveMap &map) const
 
virtual bool save (const GA_Primitive *prim, UT_JSONValue &v, const GA_SaveMap &map) const
 Save a single primitive to a UT_JSONValue. More...
 
virtual bool load (GA_Primitive *prim, UT_JSONParser &p, const GA_LoadMap &map) const
 
virtual bool load (GA_Primitive *prim, UT_JSONParser &p, const UT_JSONValue &value, const GA_LoadMap &map) const
 Load a single primitive from a UT_JSONValue. More...
 

Protected Member Functions

bool isBase (int i) const
 
int getLocal (int i) const
 
- Protected Member Functions inherited from GA_PrimitiveJSON
virtual bool getRunFields (const GA_Primitive **list, int list_size, const GA_SaveMap &save, UT_StringArray &varying, UT_JSONValue &uniform, uint &user_flags) const
 
virtual bool matchRun (const GA_Primitive *prim0, const GA_Primitive *prim1, const UT_StringArray &varying, const UT_JSONValue &uniform, uint user_flags) const
 
virtual bool saveRunFields (const GA_Primitive *prim, const GA_SaveMap &save, const UT_StringArray &varying, UT_JSONWriter &w, uint user_flags) const
 
virtual bool load (GA_Primitive *prim, UT_JSONParser &p, const GA_LoadMap &load, const UT_StringArray &varying, const GA_JSONUniformBlock &uniform) const
 
virtual bool loadUniform (GA_Primitive *prim, UT_JSONParser &p, const GA_LoadMap &map, const GA_JSONUniformBlock &uniform) const
 
virtual bool loadUnknownToken (GA_Primitive *prim, const char *token, UT_JSONParser &p, const GA_LoadMap &load) const
 
void init ()
 

Protected Attributes

const GA_PrimitiveJSONmyBase
 
int myBaseEntries
 
- Protected Attributes inherited from GA_PrimitiveJSON
UT_FSAmyTokens
 
int myEntries
 

Detailed Description

Class which extends an existing JSON schema.

Definition at line 28 of file GA_PrimitiveJSONExtend.h.

Constructor & Destructor Documentation

GA_PrimitiveJSONExtend::GA_PrimitiveJSONExtend ( const GA_PrimitiveJSON base)
virtual GA_PrimitiveJSONExtend::~GA_PrimitiveJSONExtend ( )
virtual

Member Function Documentation

virtual int GA_PrimitiveJSONExtend::getEntries ( ) const
virtual

Methods implemented from base GA_PrimitiveJSON. These methods are all implemented as:

if (isBase(i))
myBase->method(i, ...);
else
localMethod(getLocal(i), ...);

Return the number of data fields in the primitive private schema

Implements GA_PrimitiveJSON.

virtual const UT_StringHolder& GA_PrimitiveJSONExtend::getKeyword ( int  i) const
virtual

Methods implemented from base GA_PrimitiveJSON. These methods are all implemented as:

if (isBase(i))
myBase->method(i, ...);
else
localMethod(getLocal(i), ...);

Return the number of data fields in the primitive private schema

Implements GA_PrimitiveJSON.

int GA_PrimitiveJSONExtend::getLocal ( int  i) const
inlineprotected

Definition at line 84 of file GA_PrimitiveJSONExtend.h.

bool GA_PrimitiveJSONExtend::isBase ( int  i) const
inlineprotected

Definition at line 83 of file GA_PrimitiveJSONExtend.h.

virtual bool GA_PrimitiveJSONExtend::isEqual ( int  i,
const GA_Primitive prim1,
const GA_Primitive prim2 
) const
virtual

Methods implemented from base GA_PrimitiveJSON. These methods are all implemented as:

if (isBase(i))
myBase->method(i, ...);
else
localMethod(getLocal(i), ...);

Return the number of data fields in the primitive private schema

Implements GA_PrimitiveJSON.

virtual bool GA_PrimitiveJSONExtend::loadField ( GA_Primitive prim,
int  i,
UT_JSONParser p,
const GA_LoadMap map 
) const
virtual

Methods implemented from base GA_PrimitiveJSON. These methods are all implemented as:

if (isBase(i))
myBase->method(i, ...);
else
localMethod(getLocal(i), ...);

Return the number of data fields in the primitive private schema

Implements GA_PrimitiveJSON.

virtual bool GA_PrimitiveJSONExtend::loadField ( GA_Primitive prim,
int  i,
UT_JSONParser p,
const UT_JSONValue value,
const GA_LoadMap map 
) const
virtual

Methods implemented from base GA_PrimitiveJSON. These methods are all implemented as:

if (isBase(i))
myBase->method(i, ...);
else
localMethod(getLocal(i), ...);

Return the number of data fields in the primitive private schema

Reimplemented from GA_PrimitiveJSON.

virtual int GA_PrimitiveJSONExtend::localEntries ( ) const
pure virtual

The local methods return information about the local schema (i.e. the extending schema. All indices (i) are 0 based.

virtual bool GA_PrimitiveJSONExtend::localIsEqual ( int  i,
const GA_Primitive prim1,
const GA_Primitive prim2 
) const
pure virtual

The local methods return information about the local schema (i.e. the extending schema. All indices (i) are 0 based.

virtual const UT_StringHolder& GA_PrimitiveJSONExtend::localKeyword ( int  i) const
pure virtual

The local methods return information about the local schema (i.e. the extending schema. All indices (i) are 0 based.

virtual bool GA_PrimitiveJSONExtend::localLoad ( GA_Primitive prim,
int  i,
UT_JSONParser p,
const GA_LoadMap map 
) const
pure virtual

The local methods return information about the local schema (i.e. the extending schema. All indices (i) are 0 based.

virtual bool GA_PrimitiveJSONExtend::localLoad ( GA_Primitive prim,
int  i,
UT_JSONParser p,
const UT_JSONValue value,
const GA_LoadMap map 
) const
pure virtual

The local methods return information about the local schema (i.e. the extending schema. All indices (i) are 0 based.

virtual bool GA_PrimitiveJSONExtend::localSave ( const GA_Primitive prim,
int  i,
UT_JSONWriter w,
const GA_SaveMap map 
) const
pure virtual

The local methods return information about the local schema (i.e. the extending schema. All indices (i) are 0 based.

virtual bool GA_PrimitiveJSONExtend::localSave ( const GA_Primitive prim,
int  i,
UT_JSONValue value,
const GA_SaveMap map 
) const
pure virtual

The local methods return information about the local schema (i.e. the extending schema. All indices (i) are 0 based.

virtual bool GA_PrimitiveJSONExtend::saveField ( const GA_Primitive prim,
int  i,
UT_JSONWriter w,
const GA_SaveMap map 
) const
virtual

Methods implemented from base GA_PrimitiveJSON. These methods are all implemented as:

if (isBase(i))
myBase->method(i, ...);
else
localMethod(getLocal(i), ...);

Return the number of data fields in the primitive private schema

Implements GA_PrimitiveJSON.

virtual bool GA_PrimitiveJSONExtend::saveField ( const GA_Primitive prim,
int  i,
UT_JSONValue value,
const GA_SaveMap map 
) const
virtual

Methods implemented from base GA_PrimitiveJSON. These methods are all implemented as:

if (isBase(i))
myBase->method(i, ...);
else
localMethod(getLocal(i), ...);

Return the number of data fields in the primitive private schema

Reimplemented from GA_PrimitiveJSON.

Member Data Documentation

const GA_PrimitiveJSON* GA_PrimitiveJSONExtend::myBase
protected

Definition at line 86 of file GA_PrimitiveJSONExtend.h.

int GA_PrimitiveJSONExtend::myBaseEntries
protected

Definition at line 87 of file GA_PrimitiveJSONExtend.h.


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