41 mutable unsigned char *mP;
42 unsigned char *mStart;
45 void verifyBound(
int size )
const;
47 template<
typename T>
void read( T& v )
const 49 verifyBound(
sizeof v );
50 memcpy( &v, mP,
sizeof v );
54 template<
typename T>
void write( T& v )
const 56 verifyBound(
sizeof v );
57 memcpy( mP, &v,
sizeof v );
80 inline void operator+=(
int n ) { verifyBound( n ); mP += n; }
82 inline operator unsigned char *()
const {
return mP; }
83 inline int size()
const {
return mEnd - mStart; }
96 mutable unsigned char *
mP;
102 void verifyBound(
int size )
const;
105 template<
typename T>
void read( T& v )
const 107 verifyBound(
sizeof v );
108 memcpy( &v, mP,
sizeof( v ) );
129 inline void operator+=(
int n ) { verifyBound( n ); mP += n; }
132 inline operator const unsigned char *()
const {
return mP; }
136 #endif // QGSWKBPTR_H const QgsWkbPtr & operator>>(int &v) const
static void endian_swap(T &value)
Swap the endianness of the specified value.
const QgsWkbPtr & operator>>(double &v) const
QgsWkbException(QString const &what)
const QgsConstWkbPtr & operator>>(char &v) const
WkbType
Used for symbology operations.
const QgsConstWkbPtr & operator>>(float &r) const
QDataStream & operator>>(QDataStream &in, QgsFeature &feature)
Reads a feature from stream in into feature.
const QgsWkbPtr & operator>>(float &r) const
const QgsWkbPtr & operator>>(char &v) const
QgsWkbPtr & operator<<(const int &v)
const QgsConstWkbPtr & operator>>(double &v) const
QgsWkbPtr & operator<<(const QgsWKBTypes::Type &v)
const QgsWkbPtr & operator>>(QgsWKBTypes::Type &v) const
QgsWkbPtr & operator<<(const double &v)
QgsWkbPtr & operator<<(const QGis::WkbType &v)
const QgsConstWkbPtr & operator>>(int &v) const
const QgsConstWkbPtr & operator>>(unsigned int &v) const
QgsWkbPtr & operator<<(const float &r)
QgsWkbPtr & operator<<(const unsigned int &v)
const QgsWkbPtr & operator>>(unsigned int &v) const
const QgsWkbPtr & operator>>(QGis::WkbType &v) const
QgsWKBTypes::Type mWkbType
void read(T &v) const
Read a value.
Defines a qgis exception class.
QgsWkbPtr & operator<<(const char &v)