QGIS/python/core/qgsspatialindex.sip

97 lines
2.3 KiB
Plaintext
Raw Normal View History

2017-05-22 09:01:45 +02:00
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/qgsspatialindex.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/
class QgsSpatialIndex
{
2017-05-22 09:01:45 +02:00
%TypeHeaderCode
#include "qgsspatialindex.h"
%End
public:
QgsSpatialIndex();
2017-05-22 09:01:45 +02:00
%Docstring
Constructor - creates R-tree
%End
explicit QgsSpatialIndex( const QgsFeatureIterator &fi );
2017-05-22 09:01:45 +02:00
%Docstring
Constructor - creates R-tree and bulk loads it with features from the iterator.
This is much faster approach than creating an empty index and then inserting features one by one.
.. versionadded:: 2.8
%End
QgsSpatialIndex( const QgsSpatialIndex &other );
2017-05-22 09:01:45 +02:00
%Docstring
Copy constructor
%End
~QgsSpatialIndex();
2017-05-22 09:01:45 +02:00
%Docstring
Destructor finalizes work with spatial index
%End
bool insertFeature( const QgsFeature &f );
2017-05-22 09:01:45 +02:00
%Docstring
Add feature to index
:rtype: bool
%End
bool deleteFeature( const QgsFeature &f );
2017-05-22 09:01:45 +02:00
%Docstring
Remove feature from index
:rtype: bool
%End
2017-05-22 09:01:45 +02:00
QList<QgsFeatureId> intersects( const QgsRectangle &rect ) const;
%Docstring
Returns features that intersect the specified rectangle
:rtype: list of QgsFeatureId
%End
2017-05-22 09:01:45 +02:00
QList<QgsFeatureId> nearestNeighbor( const QgsPoint &point, int neighbors ) const;
%Docstring
Returns nearest neighbors (their count is specified by second parameter)
:rtype: list of QgsFeatureId
%End
2014-05-27 23:22:50 +02:00
2017-05-22 09:01:45 +02:00
int refs() const;
%Docstring
get reference count - just for debugging!
:rtype: QAtomicInt
%End
protected:
};
2017-05-22 09:01:45 +02:00
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/qgsspatialindex.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/