SMTK  @SMTK_VERSION@
Simulation Modeling Tool Kit
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
smtk::model::EntityIterator Class Reference
Collaboration diagram for smtk::model::EntityIterator:
[legend]

Public Member Functions

template<typename C >
void traverse (C ebegin, C eend)
 Iterate over the given entities and only those entities.
 
template<typename C >
void traverse (C ebegin, C eend, IteratorStyle style)
 Iterate over the given entities and the specified related records.
 
void traverse (const EntityRef &x)
 
void traverse (const EntityRef &x, IteratorStyle style)
 
void begin ()
 
void end ()
 
bool advance ()
 Advance to the next item, returning true until reaching the end of iteration.
 
bool isAtEnd () const
 Return true when iteration complete, false otherwise.
 
EntityRef operator++ ()
 Prefix increment operator. More...
 
EntityRef operator++ (int i)
 Postfix increment operator. More...
 
EntityRef operator* () const
 A convenience that returns this->current().
 
const EntityRefoperator-> () const
 A convenience that returns this->current().
 
const EntityRefcurrent () const
 Return the current value of the iterator (or an invalid cursor).
 

Protected Member Functions

void updateQueue (const EntityRef &ent)
 Add entities related to ent to the queue as required by the style. More...
 

Protected Attributes

EntityRefs m_queue
 
EntityRefs m_visited
 
IteratorStyle m_related
 

Member Function Documentation

◆ operator++() [1/2]

EntityRef smtk::model::EntityIterator::operator++ ( )

Prefix increment operator.

This advances the iterator and returns the newly-updated current item.

◆ operator++() [2/2]

EntityRef smtk::model::EntityIterator::operator++ ( int  i)

Postfix increment operator.

This advances the iterator but returns the item that was current before advancing the iterator.

◆ updateQueue()

void smtk::model::EntityIterator::updateQueue ( const EntityRef ent)
protected

Add entities related to ent to the queue as required by the style.

Used by next and the increment-operators to append items to the queue when iterating over models for the first time.


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