QueryProcessor.Utils.RegIdx
Class WindsurfRegIndexMtreeCursors

java.lang.Object
  extended by QueryProcessor.Utils.RegIdx.WindsurfRegIndexMtreeCursors

public class WindsurfRegIndexMtreeCursors
extends java.lang.Object

Class performing region index scans for Windsurf using M-tree.


Constructor Summary
WindsurfRegIndexMtreeCursors(java.lang.String filename)
          Basic constructor.
 
Method Summary
 boolean closeCursors()
          Deletes the previously created region cursors for sorted access.
 boolean createCursors(WindsurfImage query)
          Creates cursors for performing sorted access on the index using all the regions of a given image.
 int getDistances()
          Returns the number of distance computations performed by the region index.
 ScoredResultImage getNextResult(int index)
          Performs a sorted access on one of the existing region cursors.
 boolean resetDistances()
          Resets the number of distance computations performed by the region index.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WindsurfRegIndexMtreeCursors

public WindsurfRegIndexMtreeCursors(java.lang.String filename)
Basic constructor.

Parameters:
filename - The absolute path of the file containing the M-tree index.
Method Detail

createCursors

public boolean createCursors(WindsurfImage query)
Creates cursors for performing sorted access on the index using all the regions of a given image.

Parameters:
query - The query image.
Returns:
true if the cursors were successfully created, false otherwise.

closeCursors

public boolean closeCursors()
Deletes the previously created region cursors for sorted access.

Returns:
true if the cursors were successfully deleted, false otherwise.

getNextResult

public ScoredResultImage getNextResult(int index)
Performs a sorted access on one of the existing region cursors.

Parameters:
index - The cursor that should perform the sorted access.
Returns:
The next region of the requested cursor.

resetDistances

public boolean resetDistances()
Resets the number of distance computations performed by the region index.

Returns:
true if the count was successfully reset, false otherwise.

getDistances

public int getDistances()
Returns the number of distance computations performed by the region index.

Returns:
Number of distance computations performed by the region index.