GA_AttributeSet Class Reference

#include <GA_AttributeSet.h>

List of all members.

Classes

class  namecertificate

Public Member Functions

 ~GA_AttributeSet ()
GA_AttributecreateAttribute (GA_AttributeOwner owner, GA_AttributeScope scope, const char *name, const UT_Options *creation_args, const UT_Options *attribute_options, const char *style, const GA_ReuseStrategy &r=GA_ReuseStrategy())
GA_AttributecreateAttribute (GA_AttributeOwner owner, const char *name, const UT_Options *creation_args, const UT_Options *attribute_options, const char *style, const GA_ReuseStrategy &r=GA_ReuseStrategy())
 Convenience method to add a public attribute.
GA_AttributecloneAttribute (GA_AttributeOwner owner, const char *name, const GA_Attribute &src, bool clone_options)
GA_AttributecreateTempAttribute (GA_AttributeOwner owner, const UT_Options *creation_args, const UT_Options *attribute_options, const char *style)
GA_AttributecloneTempAttribute (GA_AttributeOwner owner, const GA_Attribute &src, bool clone_options)
const GA_AttributefindAttribute (GA_AttributeScope scope, const char *name, const GA_AttributeOwner search_order[], int search_order_size) const
GA_AttributefindAttribute (GA_AttributeScope scope, const char *name, const GA_AttributeOwner search_order[], int search_order_size)
const GA_AttributefindAttribute (const char *name, const GA_AttributeOwner search_order[], int search_order_size) const
GA_AttributefindAttribute (const char *name, const GA_AttributeOwner search_order[], int search_order_size)
GA_AttributefindAttribute (GA_AttributeOwner owner, GA_AttributeScope scope, const char *name)
GA_AttributefindAttribute (GA_AttributeOwner owner, const char *name)
const GA_AttributefindAttribute (GA_AttributeOwner owner, GA_AttributeScope scope, const char *name) const
const GA_AttributefindAttribute (GA_AttributeOwner owner, const char *name) const
void matchAttributes (const GA_AttributeFilter &filter, const GA_AttributeOwner search_order[], int search_order_size, UT_PtrArray< GA_Attribute * > &list)
void matchAttributes (const GA_AttributeFilter &filter, const GA_AttributeOwner search_order[], int search_order_size, UT_PtrArray< const GA_Attribute * > &list) const
void matchAttributes (const GA_AttributeFilter &filter, GA_AttributeOwner owner, UT_PtrArray< GA_Attribute * > &list)
void matchAttributes (const GA_AttributeFilter &filter, GA_AttributeOwner owner, UT_PtrArray< const GA_Attribute * > &list) const
bool destroyAttribute (GA_Attribute *attribute)
bool destroyAttribute (GA_AttributeOwner owner, GA_AttributeScope scope, const char *name)
bool destroyAttribute (GA_AttributeOwner owner, const char *name)
int destroyAttributes (GA_AttributeOwner owner, const GA_AttributeFilter &filter)
bool renameAttribute (GA_AttributeOwner owner, GA_AttributeScope scope, const char *fromName, const char *toName)
const char * renameAttributeUnspecified (GA_AttributeOwner owner, GA_AttributeScope scope, const char *fromName)
GA_AttributecreateTupleAttribute (GA_AttributeOwner owner, GA_AttributeScope scope, const char *name, GA_Storage storage, int tuple_size, const GA_Defaults &defaults, const UT_Options *creation_args=0, const UT_Options *attribute_options=0, const char *style="numeric", const GA_ReuseStrategy &r=GA_ReuseStrategy())
GA_AttributecreateTupleAttribute (GA_AttributeOwner owner, const char *name, GA_Storage storage, int tuple_size, const GA_Defaults &defaults, const UT_Options *creation_args=0, const UT_Options *attribute_options=0, const char *style="numeric", const GA_ReuseStrategy &r=GA_ReuseStrategy())
GA_AttributecreateTempTupleAttribute (GA_AttributeOwner owner, GA_Storage storage, int tuple_size, const GA_Defaults &defaults, const UT_Options *creation_args=0, const UT_Options *attribute_options=0, const char *style="numeric")
GA_AttributecreateStringAttribute (GA_AttributeOwner owner, GA_AttributeScope scope, const char *name, int tuple_size=1, const UT_Options *creation_args=0, const UT_Options *attribute_options=0, const char *style="string", const GA_ReuseStrategy &r=GA_ReuseStrategy())
GA_AttributecreateStringAttribute (GA_AttributeOwner owner, const char *name, int tuple_size=1, const UT_Options *creation_args=0, const UT_Options *attribute_options=0, const char *style="string", const GA_ReuseStrategy &r=GA_ReuseStrategy())
GA_AttributecreateTempStringAttribute (GA_AttributeOwner owner, int tuple_size=1)
GA_AttributefindPointAttribute (GA_AttributeScope scope, const char *name)
GA_AttributefindPointAttribute (const char *name)
GA_AttributefindVertexAttribute (GA_AttributeScope scope, const char *name)
GA_AttributefindVertexAttribute (const char *name)
GA_AttributefindPrimitiveAttribute (GA_AttributeScope scope, const char *name)
GA_AttributefindPrimitiveAttribute (const char *name)
GA_AttributefindGlobalAttribute (GA_AttributeScope scope, const char *name)
GA_AttributefindGlobalAttribute (const char *name)
GA_ATIGroupBoolcreateGroup (GA_AttributeOwner owner, const char *name, GA_ElementGroup &group, bool ordered=false)
GA_ATIGroupBoolcreateGroup (GA_AttributeOwner owner, const char *name, namecertificate, GA_ElementGroup &group, bool ordered=false)
GA_ATIGroupBoolfindGroup (GA_AttributeOwner owner, const char *name)
bool destroyGroup (GA_AttributeOwner owner, const char *name)
bool destroyGroup (GA_ATIGroupBool *group)
GA_Size destroyGroups (GA_AttributeOwner owner, const GA_AttributeFilter &filter)
GA_ATIGroupBoolfindPointGroup (const char *name)
GA_ATIGroupBoolfindVertexGroup (const char *name)
GA_ATIGroupBoolfindPrimitiveGroup (const char *name)
GA_ATIGroupBoolfindGlobalGroup (const char *name)
bool jsonSave (UT_JSONWriter &w, const GA_SaveMap &s) const
bool jsonLoad (UT_JSONParser &p, GA_LoadMap &m)
 Load attribute sets from a JSON stream.
int64 getMemoryUsage () const
bool loadDictH9 (UT_IStream &is, GA_AttributeOwner owner, int tbl_size, const GA_AIFDefinition< GA_AIFFileH9 > &definition, UT_RefArray< GA_AttribLoadDataH9 > &list, const GA_AttribXlateH9 *xlate)
bool stat (GA_Stat &stat, uint level) const
 Get information about attributes.
GA_DetailgetDetail () const
void clearAllAttributes (bool for_deletion)
void prepareSymbolTablesForDeletion ()
void restoreSymbolTablesFromDeletion ()
void reserveNewSymbolTableSpace (GA_AttributeOwner owner, int size)
GA_ATITopologycreateTopologyAttribute (GA_AttributeOwner owner, const char *name)
const GA_AttributeDictgetDict (GA_AttributeOwner owner) const
 Raw access to the GA_AttributeDict for a particular owner.
GA_AttributeDict::iterator begin (GA_AttributeOwner owner) const
GA_AttributeDict::iterator begin (GA_AttributeOwner owner, GA_AttributeScope scope) const
GA_AttributeDict::iterator end (GA_AttributeOwner owner) const
GA_AttributeDict::iterator end (GA_AttributeOwner owner, GA_AttributeScope scope) const
void defragment (const GA_Defragment &defrag)

Static Public Member Functions

static bool jsonStat (UT_JSONParser &p, GA_Stat &sbuf)
 Stat attribute stats from a JSON stream.
static bool saveDictH9 (ostream &os, const char *label, const UT_RefArray< GA_AttribSaveDataH9 > &list)
static bool isValidName (const char *name)
 Query whether a given string is a valid variable name.
static const char * makeFullName (UT_WorkBuffer &storage, GA_AttributeScope scope, const char *validated_base_name)
static const char * getBaseName (UT_WorkBuffer &storage, GA_AttributeScope scope, const char *full_name)

Friends

class GA_Detail


Detailed Description

Definition at line 49 of file GA_AttributeSet.h.


Constructor & Destructor Documentation

GA_AttributeSet::~GA_AttributeSet (  ) 


Member Function Documentation

GA_AttributeDict::iterator GA_AttributeSet::begin ( GA_AttributeOwner  owner,
GA_AttributeScope  scope 
) const [inline]

Definition at line 445 of file GA_AttributeSet.h.

GA_AttributeDict::iterator GA_AttributeSet::begin ( GA_AttributeOwner  owner  )  const [inline]

Definition at line 441 of file GA_AttributeSet.h.

void GA_AttributeSet::clearAllAttributes ( bool  for_deletion  ) 

GA_Attribute* GA_AttributeSet::cloneAttribute ( GA_AttributeOwner  owner,
const char *  name,
const GA_Attribute src,
bool  clone_options 
)

GA_Attribute* GA_AttributeSet::cloneTempAttribute ( GA_AttributeOwner  owner,
const GA_Attribute src,
bool  clone_options 
)

GA_Attribute* GA_AttributeSet::createAttribute ( GA_AttributeOwner  owner,
const char *  name,
const UT_Options creation_args,
const UT_Options attribute_options,
const char *  style,
const GA_ReuseStrategy r = GA_ReuseStrategy() 
) [inline]

Convenience method to add a public attribute.

Definition at line 82 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::createAttribute ( GA_AttributeOwner  owner,
GA_AttributeScope  scope,
const char *  name,
const UT_Options creation_args,
const UT_Options attribute_options,
const char *  style,
const GA_ReuseStrategy r = GA_ReuseStrategy() 
)

Create a new named attribute for the owner with the given

The creation_options are used to pass intrinsic properties to the attribute. The creation_options are not generally stored with the attribute itself, but are used to determine the intrinsic behaviour of the attribute (i.e. specifying storage types for numeric attributes).

The attribute_options are stored on the attribute.

The style argument is used to look up the attribute type. Common values include numeric, "string" and "indexpair"

GA_ATIGroupBool* GA_AttributeSet::createGroup ( GA_AttributeOwner  owner,
const char *  name,
namecertificate  ,
GA_ElementGroup group,
bool  ordered = false 
)

GA_ATIGroupBool* GA_AttributeSet::createGroup ( GA_AttributeOwner  owner,
const char *  name,
GA_ElementGroup group,
bool  ordered = false 
)

GA_Attribute* GA_AttributeSet::createStringAttribute ( GA_AttributeOwner  owner,
const char *  name,
int  tuple_size = 1,
const UT_Options creation_args = 0,
const UT_Options attribute_options = 0,
const char *  style = "string",
const GA_ReuseStrategy r = GA_ReuseStrategy() 
) [inline]

Definition at line 237 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::createStringAttribute ( GA_AttributeOwner  owner,
GA_AttributeScope  scope,
const char *  name,
int  tuple_size = 1,
const UT_Options creation_args = 0,
const UT_Options attribute_options = 0,
const char *  style = "string",
const GA_ReuseStrategy r = GA_ReuseStrategy() 
)

GA_Attribute* GA_AttributeSet::createTempAttribute ( GA_AttributeOwner  owner,
const UT_Options creation_args,
const UT_Options attribute_options,
const char *  style 
)

Create a temporary attribute. See createAttribute() for details on arguments

GA_Attribute* GA_AttributeSet::createTempStringAttribute ( GA_AttributeOwner  owner,
int  tuple_size = 1 
)

GA_Attribute* GA_AttributeSet::createTempTupleAttribute ( GA_AttributeOwner  owner,
GA_Storage  storage,
int  tuple_size,
const GA_Defaults defaults,
const UT_Options creation_args = 0,
const UT_Options attribute_options = 0,
const char *  style = "numeric" 
)

GA_ATITopology* GA_AttributeSet::createTopologyAttribute ( GA_AttributeOwner  owner,
const char *  name 
)

GA_Attribute* GA_AttributeSet::createTupleAttribute ( GA_AttributeOwner  owner,
const char *  name,
GA_Storage  storage,
int  tuple_size,
const GA_Defaults defaults,
const UT_Options creation_args = 0,
const UT_Options attribute_options = 0,
const char *  style = "numeric",
const GA_ReuseStrategy r = GA_ReuseStrategy() 
) [inline]

Definition at line 208 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::createTupleAttribute ( GA_AttributeOwner  owner,
GA_AttributeScope  scope,
const char *  name,
GA_Storage  storage,
int  tuple_size,
const GA_Defaults defaults,
const UT_Options creation_args = 0,
const UT_Options attribute_options = 0,
const char *  style = "numeric",
const GA_ReuseStrategy r = GA_ReuseStrategy() 
)

void GA_AttributeSet::defragment ( const GA_Defragment defrag  ) 

bool GA_AttributeSet::destroyAttribute ( GA_AttributeOwner  owner,
const char *  name 
) [inline]

Definition at line 177 of file GA_AttributeSet.h.

bool GA_AttributeSet::destroyAttribute ( GA_AttributeOwner  owner,
GA_AttributeScope  scope,
const char *  name 
)

bool GA_AttributeSet::destroyAttribute ( GA_Attribute attribute  ) 

int GA_AttributeSet::destroyAttributes ( GA_AttributeOwner  owner,
const GA_AttributeFilter filter 
)

bool GA_AttributeSet::destroyGroup ( GA_ATIGroupBool group  ) 

bool GA_AttributeSet::destroyGroup ( GA_AttributeOwner  owner,
const char *  name 
)

GA_Size GA_AttributeSet::destroyGroups ( GA_AttributeOwner  owner,
const GA_AttributeFilter filter 
)

GA_AttributeDict::iterator GA_AttributeSet::end ( GA_AttributeOwner  owner,
GA_AttributeScope  scope 
) const [inline]

Definition at line 452 of file GA_AttributeSet.h.

GA_AttributeDict::iterator GA_AttributeSet::end ( GA_AttributeOwner  owner  )  const [inline]

Definition at line 450 of file GA_AttributeSet.h.

const GA_Attribute* GA_AttributeSet::findAttribute ( GA_AttributeOwner  owner,
const char *  name 
) const [inline]

Definition at line 151 of file GA_AttributeSet.h.

const GA_Attribute* GA_AttributeSet::findAttribute ( GA_AttributeOwner  owner,
GA_AttributeScope  scope,
const char *  name 
) const [inline]

Definition at line 147 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::findAttribute ( GA_AttributeOwner  owner,
const char *  name 
) [inline]

Definition at line 141 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::findAttribute ( GA_AttributeOwner  owner,
GA_AttributeScope  scope,
const char *  name 
) [inline]

Definition at line 137 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::findAttribute ( const char *  name,
const GA_AttributeOwner  search_order[],
int  search_order_size 
) [inline]

Definition at line 129 of file GA_AttributeSet.h.

const GA_Attribute* GA_AttributeSet::findAttribute ( const char *  name,
const GA_AttributeOwner  search_order[],
int  search_order_size 
) const [inline]

Definition at line 121 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::findAttribute ( GA_AttributeScope  scope,
const char *  name,
const GA_AttributeOwner  search_order[],
int  search_order_size 
) [inline]

Definition at line 110 of file GA_AttributeSet.h.

const GA_Attribute* GA_AttributeSet::findAttribute ( GA_AttributeScope  scope,
const char *  name,
const GA_AttributeOwner  search_order[],
int  search_order_size 
) const

GA_Attribute* GA_AttributeSet::findGlobalAttribute ( const char *  name  )  [inline]

Definition at line 290 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::findGlobalAttribute ( GA_AttributeScope  scope,
const char *  name 
) [inline]

Definition at line 284 of file GA_AttributeSet.h.

GA_ATIGroupBool* GA_AttributeSet::findGlobalGroup ( const char *  name  )  [inline]

Definition at line 328 of file GA_AttributeSet.h.

GA_ATIGroupBool* GA_AttributeSet::findGroup ( GA_AttributeOwner  owner,
const char *  name 
)

GA_Attribute* GA_AttributeSet::findPointAttribute ( const char *  name  )  [inline]

Definition at line 257 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::findPointAttribute ( GA_AttributeScope  scope,
const char *  name 
) [inline]

Definition at line 251 of file GA_AttributeSet.h.

GA_ATIGroupBool* GA_AttributeSet::findPointGroup ( const char *  name  )  [inline]

Definition at line 322 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::findPrimitiveAttribute ( const char *  name  )  [inline]

Definition at line 279 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::findPrimitiveAttribute ( GA_AttributeScope  scope,
const char *  name 
) [inline]

Definition at line 273 of file GA_AttributeSet.h.

GA_ATIGroupBool* GA_AttributeSet::findPrimitiveGroup ( const char *  name  )  [inline]

Definition at line 326 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::findVertexAttribute ( const char *  name  )  [inline]

Definition at line 268 of file GA_AttributeSet.h.

GA_Attribute* GA_AttributeSet::findVertexAttribute ( GA_AttributeScope  scope,
const char *  name 
) [inline]

Definition at line 262 of file GA_AttributeSet.h.

GA_ATIGroupBool* GA_AttributeSet::findVertexGroup ( const char *  name  )  [inline]

Definition at line 324 of file GA_AttributeSet.h.

static const char* GA_AttributeSet::getBaseName ( UT_WorkBuffer storage,
GA_AttributeScope  scope,
const char *  full_name 
) [static]

Given the full attribute name appropriate for the given scope, get the corresponding (validated) base name.

GA_Detail* GA_AttributeSet::getDetail (  )  const [inline]

Definition at line 396 of file GA_AttributeSet.h.

const GA_AttributeDict& GA_AttributeSet::getDict ( GA_AttributeOwner  owner  )  const [inline]

Raw access to the GA_AttributeDict for a particular owner.

Definition at line 412 of file GA_AttributeSet.h.

int64 GA_AttributeSet::getMemoryUsage (  )  const

static bool GA_AttributeSet::isValidName ( const char *  name  )  [static]

Query whether a given string is a valid variable name.

bool GA_AttributeSet::jsonLoad ( UT_JSONParser p,
GA_LoadMap m 
)

Load attribute sets from a JSON stream.

bool GA_AttributeSet::jsonSave ( UT_JSONWriter w,
const GA_SaveMap s 
) const

Save attribute sets to a JSON stream.

JSON Schema: GA_AttributeSet

Storage for a set of attributes.

 {
     "name"          : "GA_AttributeSet",
     "description"   : "Attribute storage",
     "type"          : "orderedmap",
     "properties": {
         "vertexattributes": {
             "type"      : "array",
             "items"     : { "$ref" : "GA_Attribute" } ,
             "description" : "Vertex attributes",
             "optional"  : true,
         }
         "pointattributes": {
             "type"      : "array",
             "items"     : { "$ref" : "GA_Attribute" } ,
             "description" : "Point attributes",
             "optional"  : true,
         }
         "primitiveattributes": {
             "type"      : "array",
             "items"     : { "$ref" : "GA_Attribute" },
             "description" : "Primitive attributes",
             "optional"  : true,
         }
         "globalattributes": {
             "type"      : "array",
             "items"     : { "$ref" : "GA_Attribute" } ,
             "description" : "Global attributes",
             "optional"  : true,
         }
     }
 }
See also:
JSON_FileFormat, GA_AIFJSON, GA_Attribute

static bool GA_AttributeSet::jsonStat ( UT_JSONParser p,
GA_Stat sbuf 
) [static]

Stat attribute stats from a JSON stream.

bool GA_AttributeSet::loadDictH9 ( UT_IStream is,
GA_AttributeOwner  owner,
int  tbl_size,
const GA_AIFDefinition< GA_AIFFileH9 > &  definition,
UT_RefArray< GA_AttribLoadDataH9 > &  list,
const GA_AttribXlateH9 xlate 
)

static const char* GA_AttributeSet::makeFullName ( UT_WorkBuffer storage,
GA_AttributeScope  scope,
const char *  validated_base_name 
) [static]

Build the appropriate full attribute name from an validated base name for the given scope.

void GA_AttributeSet::matchAttributes ( const GA_AttributeFilter filter,
GA_AttributeOwner  owner,
UT_PtrArray< const GA_Attribute * > &  list 
) const [inline]

Definition at line 169 of file GA_AttributeSet.h.

void GA_AttributeSet::matchAttributes ( const GA_AttributeFilter filter,
GA_AttributeOwner  owner,
UT_PtrArray< GA_Attribute * > &  list 
) [inline]

Definition at line 165 of file GA_AttributeSet.h.

void GA_AttributeSet::matchAttributes ( const GA_AttributeFilter filter,
const GA_AttributeOwner  search_order[],
int  search_order_size,
UT_PtrArray< const GA_Attribute * > &  list 
) const

void GA_AttributeSet::matchAttributes ( const GA_AttributeFilter filter,
const GA_AttributeOwner  search_order[],
int  search_order_size,
UT_PtrArray< GA_Attribute * > &  list 
)

void GA_AttributeSet::prepareSymbolTablesForDeletion (  ) 

bool GA_AttributeSet::renameAttribute ( GA_AttributeOwner  owner,
GA_AttributeScope  scope,
const char *  fromName,
const char *  toName 
)

const char* GA_AttributeSet::renameAttributeUnspecified ( GA_AttributeOwner  owner,
GA_AttributeScope  scope,
const char *  fromName 
)

Rename an attribute to an unused name. Typically used to make fromName available for another attribute.

Returns new name on success, NULL on failure.

void GA_AttributeSet::reserveNewSymbolTableSpace ( GA_AttributeOwner  owner,
int  size 
)

void GA_AttributeSet::restoreSymbolTablesFromDeletion (  ) 

static bool GA_AttributeSet::saveDictH9 ( ostream &  os,
const char *  label,
const UT_RefArray< GA_AttribSaveDataH9 > &  list 
) [static]

bool GA_AttributeSet::stat ( GA_Stat stat,
uint  level 
) const

Get information about attributes.


Friends And Related Function Documentation

friend class GA_Detail [friend]

Only GA_Detail can create attribute sets because the attributes rely on the existense of the detail for index maps and otherwise it may be too easy to create a attributes without a detail.

Definition at line 55 of file GA_AttributeSet.h.


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

Generated on Thu Jan 31 00:30:40 2013 for HDK by  doxygen 1.5.9