22 mP =
reinterpret_cast<unsigned char *
>( wkb.data() );
24 mEnd = mP + wkb.length();
34void QgsWkbPtr::verifyBound(
int size )
const
36 if ( !mP || mP +
size > mEnd )
42 mP =
reinterpret_cast< unsigned char *
>(
const_cast<char *
>( wkb.constData() ) );
50 mP =
const_cast< unsigned char *
>( p );
88 Q_ASSERT( skipZM >= 0 );
93 points.resize( nPoints );
94 QPointF *ptr = points.data();
96 for (
unsigned int i = 0; i < nPoints; ++i, ++ptr )
WkbType
The WKB type describes the number of dimensions a geometry has.
static endian_t endian()
Returns whether this machine uses big or little endian.
QgsConstWkbPtr(const QByteArray &wkb)
Construct WKB pointer from QByteArray.
void read(T &v) const
Read a value.
void verifyBound(int size) const
Verify bounds.
Qgis::WkbType readHeader() const
readHeader
const QgsConstWkbPtr & operator>>(double &v) const
Custom exception class for Wkb related exceptions.
QgsWkbPtr(QByteArray &wkb)
Construct WKB pointer from QByteArray.
static Q_INVOKABLE int coordDimensions(Qgis::WkbType type)
Returns the coordinate dimension of the geometry type as an integer.