public class GenericRStarTreeRangeQuery<O extends SpatialComparable,D extends Distance<D>> extends AbstractDistanceRangeQuery<O,D>
Modifier and Type | Field and Description |
---|---|
protected SpatialPrimitiveDistanceFunction<? super O,D> |
distanceFunction
Spatial primitive distance function
|
protected AbstractRStarTree<?,?> |
tree
The index to use
|
distanceQuery
relation
HINT_BULK, HINT_EXACT, HINT_HEAVY_USE, HINT_NO_CACHE, HINT_OPTIMIZED_ONLY, HINT_SINGLE
Constructor and Description |
---|
GenericRStarTreeRangeQuery(AbstractRStarTree<?,?> tree,
SpatialDistanceQuery<O,D> distanceQuery)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
protected List<DistanceResultPair<D>> |
doRangeQuery(O object,
D epsilon)
Perform the actual query process.
|
List<DistanceResultPair<D>> |
getRangeForDBID(DBID id,
D range)
Get the nearest neighbors for a particular id in a given query range
|
List<DistanceResultPair<D>> |
getRangeForObject(O obj,
D range)
Get the nearest neighbors for a particular object in a given query range
|
getDistanceFactory, getRangeForBulkDBIDs
getRelation
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getRelation
protected final AbstractRStarTree<?,?> tree
protected final SpatialPrimitiveDistanceFunction<? super O extends SpatialComparable,D extends Distance<D>> distanceFunction
public GenericRStarTreeRangeQuery(AbstractRStarTree<?,?> tree, SpatialDistanceQuery<O,D> distanceQuery)
tree
- Index to usedistanceQuery
- Distance query to useprotected List<DistanceResultPair<D>> doRangeQuery(O object, D epsilon)
object
- Query objectepsilon
- Query rangepublic List<DistanceResultPair<D>> getRangeForObject(O obj, D range)
RangeQuery
getRangeForObject
in interface RangeQuery<O extends SpatialComparable,D extends Distance<D>>
getRangeForObject
in class AbstractDistanceRangeQuery<O extends SpatialComparable,D extends Distance<D>>
obj
- Query objectrange
- Query rangepublic List<DistanceResultPair<D>> getRangeForDBID(DBID id, D range)
RangeQuery
getRangeForDBID
in interface RangeQuery<O extends SpatialComparable,D extends Distance<D>>
getRangeForDBID
in class AbstractDistanceRangeQuery<O extends SpatialComparable,D extends Distance<D>>
id
- query object IDrange
- Query range