Arcane  4.1.12.0
Developer documentation
Loading...
Searching...
No Matches
Arcane::EnumeratorImplBase Class Referenceabstract

Enumerator interface. More...

#include </__w/arcaneframework.github.io/arcaneframework.github.io/framework/arccore/src/common/arccore/common/Collection.h>

Inheritance diagram for Arcane::EnumeratorImplBase:
Collaboration diagram for Arcane::EnumeratorImplBase:

Public Member Functions

virtual void reset ()=0
 Resets the enumerator.
virtual bool moveNext ()=0
 Advances the enumerator to the next element in the collection.
virtual void * current ()=0
 Current object of the enumerator.
virtual const void * current () const =0
 Current object of the enumerator.
Public Member Functions inherited from Arcane::ObjectImpl
 ObjectImpl (const ObjectImpl &rhs)=delete
ObjectImpl & operator= (const ObjectImpl &rhs)=delete
void addRef ()
 Increments the reference counter.
void removeRef ()
 Decrements the reference counter.
Int32 refCount () const
 Returns the value of the reference counter.
virtual void deleteMe ()
 Destroys this object.

Detailed Description

Enumerator interface.

This class serves as the base class for all iterator implementations. This class should not be used directly: to perform an enumeration, you must use the Enumerator class or one of its derived classes.

See also
Enumerator

Definition at line 101 of file arccore/src/common/arccore/common/Collection.h.

Member Function Documentation

◆ current() [1/2]

virtual const void * Arcane::EnumeratorImplBase::current ( ) const
pure virtual

Current object of the enumerator.

Implemented in Arcane::ListEnumeratorImplT< T >.

◆ current() [2/2]

virtual void * Arcane::EnumeratorImplBase::current ( )
pure virtual

Current object of the enumerator.

Implemented in Arcane::ListEnumeratorImplT< T >.

◆ moveNext()

virtual bool Arcane::EnumeratorImplBase::moveNext ( )
pure virtual

Advances the enumerator to the next element in the collection.

Return values
trueif the enumerator has not passed the last element. In this case, the call to current() is valid.
falseif the enumerator has passed the last element. In this case, any subsequent call to this method returns false and the call to current() is not valid.

Implemented in Arcane::ListEnumeratorImplT< T >.

◆ reset()

virtual void Arcane::EnumeratorImplBase::reset ( )
pure virtual

Resets the enumerator.

Positions the enumerator just before the first element of the collection. A moveNext() must be performed to make it valid.

Implemented in Arcane::ListEnumeratorImplT< T >.


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