QGIS API Documentation 3.34.0-Prizren (ffbdd678812)
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
QgsVertexId Class Reference

Utility class for identifying a unique vertex within a geometry. More...

#include <qgsvertexid.h>

Public Member Functions

 QgsVertexId (int _part=-1, int _ring=-1, int _vertex=-1, Qgis::VertexType _type=Qgis::VertexType::Segment)
 Constructor for QgsVertexId.
 
bool isValid () const
 Returns true if the vertex id is valid.
 
bool isValid (const QgsAbstractGeometry *geom) const
 Returns true if this vertex ID is valid for the specified geom.
 
bool operator!= (QgsVertexId other) const
 
bool operator== (QgsVertexId other) const
 
bool partEqual (QgsVertexId o) const
 Returns true if this vertex ID belongs to the same part as another vertex ID.
 
bool ringEqual (QgsVertexId o) const
 Returns true if this vertex ID belongs to the same ring as another vertex ID (i.e.
 
bool vertexEqual (QgsVertexId o) const
 Returns true if this vertex ID corresponds to the same vertex as another vertex ID (i.e.
 

Public Attributes

int part = -1
 Part number.
 
int ring = -1
 Ring number.
 
Qgis::VertexType type = Qgis::VertexType::Segment
 Vertex type.
 
int vertex = -1
 Vertex number.
 

Detailed Description

Utility class for identifying a unique vertex within a geometry.

Since
QGIS 2.10

Definition at line 30 of file qgsvertexid.h.

Constructor & Destructor Documentation

◆ QgsVertexId()

QgsVertexId::QgsVertexId ( int  _part = -1,
int  _ring = -1,
int  _vertex = -1,
Qgis::VertexType  _type = Qgis::VertexType::Segment 
)
inlineexplicit

Constructor for QgsVertexId.

Definition at line 36 of file qgsvertexid.h.

Member Function Documentation

◆ isValid() [1/2]

bool QgsVertexId::isValid ( ) const
inline

Returns true if the vertex id is valid.

Definition at line 46 of file qgsvertexid.h.

◆ isValid() [2/2]

bool QgsVertexId::isValid ( const QgsAbstractGeometry geom) const

Returns true if this vertex ID is valid for the specified geom.

Definition at line 19 of file qgsvertexid.cpp.

◆ operator!=()

bool QgsVertexId::operator!= ( QgsVertexId  other) const
inline

Definition at line 52 of file qgsvertexid.h.

◆ operator==()

bool QgsVertexId::operator== ( QgsVertexId  other) const
inline

Definition at line 48 of file qgsvertexid.h.

◆ partEqual()

bool QgsVertexId::partEqual ( QgsVertexId  o) const
inline

Returns true if this vertex ID belongs to the same part as another vertex ID.

Definition at line 60 of file qgsvertexid.h.

◆ ringEqual()

bool QgsVertexId::ringEqual ( QgsVertexId  o) const
inline

Returns true if this vertex ID belongs to the same ring as another vertex ID (i.e.

the part and ring number are equal).

Definition at line 69 of file qgsvertexid.h.

◆ vertexEqual()

bool QgsVertexId::vertexEqual ( QgsVertexId  o) const
inline

Returns true if this vertex ID corresponds to the same vertex as another vertex ID (i.e.

the part, ring number and vertex number are equal).

Definition at line 78 of file qgsvertexid.h.

Member Data Documentation

◆ part

int QgsVertexId::part = -1

Part number.

Definition at line 89 of file qgsvertexid.h.

◆ ring

int QgsVertexId::ring = -1

Ring number.

Definition at line 92 of file qgsvertexid.h.

◆ type

Vertex type.

Definition at line 98 of file qgsvertexid.h.

◆ vertex

int QgsVertexId::vertex = -1

Vertex number.

Definition at line 95 of file qgsvertexid.h.


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