public abstract class RankEvaluator extends Object implements Comparator<DataWrapper>
| Modifier and Type | Field and Description |
|---|---|
protected InclusionType |
containmentMethod
The containment method used in the query
|
protected GeoIndexType |
indexType
The index type of the Index using this RankEvaluator
|
protected Polygon |
polygon
The query polygon
|
protected com.vividsolutions.jts.geom.Envelope |
query
The query Minimal Bounding Rectangle
|
protected boolean |
reverseSort
An indicator of whether the sorting should be reversed
|
| Constructor and Description |
|---|
RankEvaluator() |
| Modifier and Type | Method and Description |
|---|---|
int |
compare(DataWrapper data1,
DataWrapper data2) |
void |
init(Polygon polygon,
InclusionType containmentMethod,
Boolean reverseSort,
GeoIndexType indexType,
String[] args)
A method called by the GeoIndexResource after creating an instance of a
RankEvaluator
|
protected abstract void |
initialize(String[] args)
The plugin specific initialization method.
|
abstract boolean |
isIndexTypeCompatible(GeoIndexType indexType)
A method used to check if this RankEvaluator plugin is compatible with
indices/entries with a specific GeoIndexType
|
abstract double |
rank(DataWrapper data)
A method used to rank a GeoIndex entry.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitequalsprotected Polygon polygon
protected com.vividsolutions.jts.geom.Envelope query
protected GeoIndexType indexType
protected InclusionType containmentMethod
protected boolean reverseSort
public final int compare(DataWrapper data1, DataWrapper data2)
compare in interface Comparator<DataWrapper>public final void init(Polygon polygon, InclusionType containmentMethod, Boolean reverseSort, GeoIndexType indexType, String[] args) throws RankEvaluatorInitializationException
polygon - -
A polygon representation of the original query of which this
RankEvaluator will rank the resultscontainmentMethod - -
The containment method used in the original queryreverseSort - -
An indicator of whether the rank evaluator should sort the
results in reverseindexType - -
The geo index type of the GeoIndex using this RankEvaluatorargs - -
Any additional plugin specific initialization arguments.RankEvaluatorInitializationException - -
An error occurex while initializing the RankEvaluatorprotected abstract void initialize(String[] args) throws RankEvaluatorInitializationException
args - -
A plugin specific array of Strings used to initialize a
RankEvaluator plugin.RankEvaluatorInitializationException - -
An error occurex while initializing the RankEvaluatorpublic abstract boolean isIndexTypeCompatible(GeoIndexType indexType)
indexType - -
The GeoIndexType of which to check the compatability with this
pluginpublic abstract double rank(DataWrapper data)
data - -
The GeoIndex entry to rank.Copyright © 2014. All Rights Reserved.