spatial
Class SelectQuery

java.lang.Object
  |
  +--spatial.BasicSpatialQuery
        |
        +--spatial.SelectQuery
All Implemented Interfaces:
SpatialQuery

public class SelectQuery
extends BasicSpatialQuery

Class offering the operations required for a selection query performed by a spatial search tree.


Field Summary
 
Fields inherited from class spatial.BasicSpatialQuery
tolerance
 
Constructor Summary
SelectQuery(int scale)
          Constructor.
 
Method Summary
 boolean conditionFulfilled(MBR rect, MBR entryMBR)
          Tests whether the minimum coordinates of the query rectangle is contained by the MBR of a non-leaf entry intersect.
 boolean conditionFulfilled(MBR rect, SpatialSearchTreeEntry entry)
          Tests whether the minimum coordinate of the query rectangle and the MBR of an leaf entry interact.
 boolean conditionFulfilled(MBR rect, SpatialSearchTreeObject obj)
          Tests whether the query rectangle and the object interact.
 
Methods inherited from class spatial.BasicSpatialQuery
areEqual, setTolerance
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SelectQuery

public SelectQuery(int scale)
Constructor.

Parameters:
scale - the scale
Method Detail

conditionFulfilled

public boolean conditionFulfilled(MBR rect,
                                  MBR entryMBR)
Tests whether the minimum coordinates of the query rectangle is contained by the MBR of a non-leaf entry intersect. The tolerance attribute is considered.

Specified by:
conditionFulfilled in interface SpatialQuery
Overrides:
conditionFulfilled in class BasicSpatialQuery
Parameters:
rect - the query rectangle
entryMBR - the minimum bounding rectangle of non-leaf entry
Returns:
true if the condition is fulfilled

conditionFulfilled

public boolean conditionFulfilled(MBR rect,
                                  SpatialSearchTreeEntry entry)
Tests whether the minimum coordinate of the query rectangle and the MBR of an leaf entry interact. The tolerance attribute is considered.

Specified by:
conditionFulfilled in interface SpatialQuery
Overrides:
conditionFulfilled in class BasicSpatialQuery
Parameters:
rect - the query rectangle
entry - the entry of a leaf entry
Returns:
true if the condition is fulfilled

conditionFulfilled

public boolean conditionFulfilled(MBR rect,
                                  SpatialSearchTreeObject obj)
Tests whether the query rectangle and the object interact. The scale attribute is considered.

Specified by:
conditionFulfilled in interface SpatialQuery
Overrides:
conditionFulfilled in class BasicSpatialQuery
Parameters:
rect - the query rectangle
obj - the object
Returns:
true if the condition fulfilled