CFx SDK Documentation  2020SP3
Public Member Functions | List of all members
OdDbObjectIterator Class Referenceabstract

#include <DbObjectIterator.h>

Inheritance diagram for OdDbObjectIterator:
OdRxObject

Public Member Functions

 ODRX_DECLARE_MEMBERS (OdDbObjectIterator)
 
 OdDbObjectIterator ()
 
virtual void start (bool atBeginning=true, bool skipErased=true)=0
 
virtual bool done () const =0
 
virtual OdDbObjectId objectId () const =0
 
virtual OdDbEntityPtr entity (OdDb::OpenMode openMode=OdDb::kForRead, bool openErasedEntity=false)=0
 
virtual void step (bool forward=true, bool skipErased=true)=0
 
virtual bool seek (OdDbObjectId objectId)=0
 
virtual bool seek (const OdDbEntity *pEntity)=0
 
- Public Member Functions inherited from OdRxObject
 ODRX_HEAP_OPERATORS ()
 
 OdRxObject ()
 
virtual ~OdRxObject ()
 
virtual OdRxObjectqueryX (const OdRxClass *pClass) const
 
virtual OdRxObjectx (const OdRxClass *pClass) const
 
virtual OdRxClassisA () const
 
virtual void addRef ()=0
 
virtual void release ()=0
 
virtual long numRefs () const
 
bool isKindOf (const OdRxClass *pClass) const
 
virtual OdRxObjectPtr clone () const
 
virtual void copyFrom (const OdRxObject *pSource)
 
virtual OdRx::Ordering comparedTo (const OdRxObject *pOther) const
 
virtual bool isEqualTo (const OdRxObject *pOther) const
 

Additional Inherited Members

- Static Public Member Functions inherited from OdRxObject
static OdRxObjectPtr cast (const OdRxObject *pointer)
 
static OdRxClassdesc ()
 

Detailed Description

This class defines bidirectional Iterator objects that traverse entities contained in complex entities.

OdDbBlock Table Records in an OdDbDatabase instance.

See also
TD_Db
Remarks
Complex entities include the following:

Iterated entities OdDbBlockReference All OdDb2dPolyline Vertex OdDb3dPolyline Vertex OdDbPolyFaceMesh Vertex OdDbPolygonMesh Vertex

This class cannot directly instantiated, but must be instantiated with the iterator creation methods of the class to be iterated through.

<group OdDb_Classes>

Definition at line 65 of file DbObjectIterator.h.

Constructor & Destructor Documentation

◆ OdDbObjectIterator()

OdDbObjectIterator::OdDbObjectIterator ( )
inline

Definition at line 70 of file DbObjectIterator.h.

Member Function Documentation

◆ done()

virtual bool OdDbObjectIterator::done ( ) const
pure virtual

Returns true if and only if the traversal by this Iterator object is complete.

◆ entity()

virtual OdDbEntityPtr OdDbObjectIterator::entity ( OdDb::OpenMode  openMode = OdDb::kForRead,
bool  openErasedEntity = false 
)
pure virtual

Opens and returns the entity currently referenced by this Iterator object.

Parameters
openMode[in] Mode in which to open the entity.
openErasedEntity[in] If and only if true, erased records will be opened or retrieved.
Returns
Returns a SmartPointer to the opened entity if successful, otherwise a null SmartPointer.

◆ objectId()

virtual OdDbObjectId OdDbObjectIterator::objectId ( ) const
pure virtual

Returns the Object ID of the entity currently referenced by this Iterator object.

◆ ODRX_DECLARE_MEMBERS()

OdDbObjectIterator::ODRX_DECLARE_MEMBERS ( OdDbObjectIterator  )

◆ seek() [1/2]

virtual bool OdDbObjectIterator::seek ( const OdDbEntity pEntity)
pure virtual

Positions this Iterator object at the specified record.

Parameters
pEntity[in] Pointer to the entity.

◆ seek() [2/2]

virtual bool OdDbObjectIterator::seek ( OdDbObjectId  objectId)
pure virtual

Positions this Iterator object at the specified record.

Parameters
objectId[in] Object ID of the entity.

◆ start()

virtual void OdDbObjectIterator::start ( bool  atBeginning = true,
bool  skipErased = true 
)
pure virtual

Sets this Iterator object to reference the entity that it would normally return first.

Remarks
Allows multiple traversals of the iterator list.
Parameters
atBeginning[in] True to start at the beginning, false to start at the end.
skipErased[in] If and only if true, erased records are skipped.

◆ step()

virtual void OdDbObjectIterator::step ( bool  forward = true,
bool  skipErased = true 
)
pure virtual

Steps this Iterator object.

Parameters
forward[in] True to step forward, false to step backward.
skipErased[in] If and only if true, erased records are skipped.

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