GA_ElementGroupOrder Class Reference

#include <GA_ElementGroupOrder.h>

List of all members.

Public Member Functions

 GA_ElementGroupOrder (GA_Attribute &attrib)
 GA_ElementGroupOrder (GA_Attribute &attrib, const GA_ElementGroupOrder &src)
 ~GA_ElementGroupOrder ()
GA_Size entries () const
 Return the total number of entries, mixed or not.
GA_Size elementEntries () const
GA_Size mixedEntries () const
GA_Offset operator() (GA_ElementGroupOrderIndex i) const
 Will return -1 if the i'th entry is a mixed entry.
GA_Offset getElement (GA_ElementGroupOrderIndex i) const
 Will return -1 if the i'th entry is a mixed entry.
void getMixed (GA_ElementGroupOrderIndex i, GA_Offset &element, const GA_SecondaryLookupInfo *&secondary) const
void clear ()
void swapRange (GA_Offset a, GA_Offset b, GA_Size n)
void moveRange (GA_Offset a, GA_Offset b, GA_Size n)
void defragment (const GA_Defragment &defrag)
void append (GA_Offset element)
bool remove (GA_Offset element)
void appendMix (GA_Offset element, const GA_SecondaryLookupInfo *secondary)
bool removeMix (GA_Offset element, const GA_SecondaryLookupInfo *secondary)
int removeAll (GA_Offset element)
int removeAll (const GA_RangeMemberQuery &range_query)
bool removeIndex (GA_ElementGroupOrderIndex i)
GA_ElementGroupOrderIndex findOffset (GA_Offset item) const
GA_ElementGroupOrderIndex findMix (GA_Offset element, const GA_SecondaryLookupInfo *s) const
void merge (const GA_ElementGroupOrder &src, const GA_MergeOffsetMap &map)
 Append any elements in src that are being merged, in order.
bool jsonSave (UT_JSONWriter &w, const GA_SaveMap &save) const
bool jsonLoad (UT_JSONParser &p, const GA_LoadMap &load)
 Load the element list from the JSON stream.
bool jsonSaveMix (UT_JSONWriter &w, const GA_SaveMap &save) const
bool jsonLoadMix (UT_JSONParser &p, const GA_LoadMap &load)
 Load the element list from the JSON stream.


Detailed Description

Definition at line 42 of file GA_ElementGroupOrder.h.


Constructor & Destructor Documentation

GA_ElementGroupOrder::GA_ElementGroupOrder ( GA_Attribute attrib  ) 

GA_ElementGroupOrder::GA_ElementGroupOrder ( GA_Attribute attrib,
const GA_ElementGroupOrder src 
)

GA_ElementGroupOrder::~GA_ElementGroupOrder (  ) 


Member Function Documentation

void GA_ElementGroupOrder::append ( GA_Offset  element  ) 

void GA_ElementGroupOrder::appendMix ( GA_Offset  element,
const GA_SecondaryLookupInfo secondary 
)

void GA_ElementGroupOrder::clear (  ) 

void GA_ElementGroupOrder::defragment ( const GA_Defragment defrag  ) 

GA_Size GA_ElementGroupOrder::elementEntries (  )  const [inline]

Return the number of un-mixed entries. ie. those indices available to getElement()

Definition at line 55 of file GA_ElementGroupOrder.h.

GA_Size GA_ElementGroupOrder::entries (  )  const

Return the total number of entries, mixed or not.

GA_ElementGroupOrderIndex GA_ElementGroupOrder::findMix ( GA_Offset  element,
const GA_SecondaryLookupInfo s 
) const

Return the index of the mixed entry passed in (or -1). This is O(N) which easily leads to O(N*N) algorithms and should be avoided at all costs.

GA_ElementGroupOrderIndex GA_ElementGroupOrder::findOffset ( GA_Offset  item  )  const

Return the index of the item passed in (or -1). This is O(N) which easily leads to O(N*N) algorithms and should be avoided at all costs.

GA_Offset GA_ElementGroupOrder::getElement ( GA_ElementGroupOrderIndex  i  )  const

Will return -1 if the i'th entry is a mixed entry.

void GA_ElementGroupOrder::getMixed ( GA_ElementGroupOrderIndex  i,
GA_Offset element,
const GA_SecondaryLookupInfo *&  secondary 
) const

Query the i'th entry as a mixed entry. Secondary is set to NULL when not mixed.

bool GA_ElementGroupOrder::jsonLoad ( UT_JSONParser p,
const GA_LoadMap load 
)

Load the element list from the JSON stream.

bool GA_ElementGroupOrder::jsonLoadMix ( UT_JSONParser p,
const GA_LoadMap load 
)

Load the element list from the JSON stream.

bool GA_ElementGroupOrder::jsonSave ( UT_JSONWriter w,
const GA_SaveMap save 
) const

Save data to a JSON file for an UNMIXED order.

JSON Schema: GA_ElementGroupOrder

 {
     "name"          : "GA_ElementGroupOrder",
     "description"   : "An array of ordered elements",
     "type"          : { "$ref" : "GA_OffsetList" },
 }
See also:
JSON_FileFormat

bool GA_ElementGroupOrder::jsonSaveMix ( UT_JSONWriter w,
const GA_SaveMap save 
) const

Save data to a JSON file for a MIXED order.

JSON Schema: GA_ElementGroupOrder

 {
     "name"          : "GA_ElementGroupOrder",
     "description"   : "An array of ordered elements",
     "type"          : { "$ref" : "GA_OffsetList" },
 }
See also:
JSON_FileFormat

void GA_ElementGroupOrder::merge ( const GA_ElementGroupOrder src,
const GA_MergeOffsetMap map 
)

Append any elements in src that are being merged, in order.

GA_Size GA_ElementGroupOrder::mixedEntries (  )  const

Return the number of mixed entries. ie. those indices available to getMixed()

void GA_ElementGroupOrder::moveRange ( GA_Offset  a,
GA_Offset  b,
GA_Size  n 
)

GA_Offset GA_ElementGroupOrder::operator() ( GA_ElementGroupOrderIndex  i  )  const [inline]

Will return -1 if the i'th entry is a mixed entry.

Definition at line 63 of file GA_ElementGroupOrder.h.

bool GA_ElementGroupOrder::remove ( GA_Offset  element  ) 

int GA_ElementGroupOrder::removeAll ( const GA_RangeMemberQuery range_query  ) 

int GA_ElementGroupOrder::removeAll ( GA_Offset  element  ) 

bool GA_ElementGroupOrder::removeIndex ( GA_ElementGroupOrderIndex  i  ) 

bool GA_ElementGroupOrder::removeMix ( GA_Offset  element,
const GA_SecondaryLookupInfo secondary 
)

void GA_ElementGroupOrder::swapRange ( GA_Offset  a,
GA_Offset  b,
GA_Size  n 
)


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

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