QGIS API Documentation
2.6.0-Brighton
|
#include <qgsspatialindex.h>
Public Member Functions | |
QgsSpatialIndex () | |
constructor - creates R-tree | |
QgsSpatialIndex (const QgsSpatialIndex &other) | |
copy constructor | |
~QgsSpatialIndex () | |
destructor finalizes work with spatial index | |
QgsSpatialIndex & | operator= (const QgsSpatialIndex &other) |
implement assignment operator | |
bool | insertFeature (const QgsFeature &f) |
add feature to index | |
bool | deleteFeature (const QgsFeature &f) |
remove feature from index | |
QList< QgsFeatureId > | intersects (QgsRectangle rect) const |
returns features that intersect the specified rectangle | |
QList< QgsFeatureId > | nearestNeighbor (QgsPoint point, int neighbors) const |
returns nearest neighbors (their count is specified by second parameter) | |
int | refs () const |
get reference count - just for debugging! |
Protected Member Functions | |
bool | featureInfo (const QgsFeature &f, SpatialIndex::Region &r, QgsFeatureId &id) |
Static Protected Member Functions | |
static SpatialIndex::Region | rectToRegion (QgsRectangle rect) |
QgsSpatialIndex::QgsSpatialIndex | ( | ) |
constructor - creates R-tree
QgsSpatialIndex::QgsSpatialIndex | ( | const QgsSpatialIndex & | other | ) |
copy constructor
QgsSpatialIndex::~QgsSpatialIndex | ( | ) |
destructor finalizes work with spatial index
bool QgsSpatialIndex::deleteFeature | ( | const QgsFeature & | f | ) |
remove feature from index
|
protected |
bool QgsSpatialIndex::insertFeature | ( | const QgsFeature & | f | ) |
add feature to index
QList< QgsFeatureId > QgsSpatialIndex::intersects | ( | QgsRectangle | rect | ) | const |
returns features that intersect the specified rectangle
QList< QgsFeatureId > QgsSpatialIndex::nearestNeighbor | ( | QgsPoint | point, |
int | neighbors | ||
) | const |
returns nearest neighbors (their count is specified by second parameter)
QgsSpatialIndex & QgsSpatialIndex::operator= | ( | const QgsSpatialIndex & | other | ) |
implement assignment operator
|
staticprotected |
int QgsSpatialIndex::refs | ( | ) | const |
get reference count - just for debugging!