15 #ifndef QGSFEATUREITERATOR_H
16 #define QGSFEATUREITERATOR_H
36 virtual bool rewind() = 0;
38 virtual bool close() = 0;
76 bool isClosed()
const;
139 return !( fi1 == fi2 );
142 #endif // QGSFEATUREITERATOR_H
Wrapper for iterator of features from vector data provider or vector layer.
virtual bool close()=0
end of iterating: free the resources / lock
bool operator==(const QgsFeatureIterator &fi1, const QgsFeatureIterator &fi2)
bool operator!=(const QgsFeatureIterator &fi1, const QgsFeatureIterator &fi2)
virtual bool rewind()=0
reset the iterator to the starting position
The feature class encapsulates a single feature including its id, geometry and a list of field/values...
bool isClosed() const
find out whether the iterator is still valid or closed already
virtual bool nextFeature(QgsFeature &f)=0
fetch next feature, return true on success
Internal feature iterator to be implemented within data providers.
QgsFeatureIterator()
construct invalid iterator
This class wraps a request for features to a vector layer (or directly its vector data provider)...
QgsFeatureRequest mRequest
QgsAbstractFeatureIterator * mIter
~QgsFeatureIterator()
destructor deletes the iterator if it has no more references
bool nextFeature(QgsFeature &f)