QGIS API Documentation 3.36.0-Maidenhead (09951dc0acf)
|
The part_iterator class provides STL-style iterator for geometry parts. More...
#include <qgsabstractgeometry.h>
Public Member Functions | |
part_iterator ()=default | |
Create invalid iterator. | |
part_iterator (QgsAbstractGeometry *g, int index) | |
Create part iterator for a geometry. | |
bool | operator!= (part_iterator other) const |
QgsAbstractGeometry * | operator* () const |
Returns the current item. | |
part_iterator & | operator++ () |
The prefix ++ operator (++it) advances the iterator to the next part and returns an iterator to the new current part. | |
part_iterator | operator++ (int) |
The postfix ++ operator (it++) advances the iterator to the next part and returns an iterator to the previously current part. | |
bool | operator== (part_iterator other) const |
int | partNumber () const |
Returns the part number of the current item. | |
The part_iterator class provides STL-style iterator for geometry parts.
Definition at line 827 of file qgsabstractgeometry.h.
|
default |
Create invalid iterator.
QgsAbstractGeometry::part_iterator::part_iterator | ( | QgsAbstractGeometry * | g, |
int | index | ||
) |
Create part iterator for a geometry.
Definition at line 546 of file qgsabstractgeometry.cpp.
|
inline |
Definition at line 857 of file qgsabstractgeometry.h.
QgsAbstractGeometry * QgsAbstractGeometry::part_iterator::operator* | ( | ) | const |
Returns the current item.
Definition at line 575 of file qgsabstractgeometry.cpp.
QgsAbstractGeometry::part_iterator & QgsAbstractGeometry::part_iterator::operator++ | ( | ) |
The prefix ++ operator (++it) advances the iterator to the next part and returns an iterator to the new current part.
Calling this function on iterator that is already past the last item leads to undefined results.
Definition at line 552 of file qgsabstractgeometry.cpp.
QgsAbstractGeometry::part_iterator QgsAbstractGeometry::part_iterator::operator++ | ( | int | ) |
The postfix ++ operator (it++) advances the iterator to the next part and returns an iterator to the previously current part.
Definition at line 568 of file qgsabstractgeometry.cpp.
bool QgsAbstractGeometry::part_iterator::operator== | ( | QgsAbstractGeometry::part_iterator | other | ) | const |
Definition at line 591 of file qgsabstractgeometry.cpp.
int QgsAbstractGeometry::part_iterator::partNumber | ( | ) | const |
Returns the part number of the current item.
Definition at line 586 of file qgsabstractgeometry.cpp.