public abstract class BBoxSimilarityValueSource extends ValueSource
ValueSource in which FunctionValues.objectVal(int) returns a Rectangle.
Implementers: remember to implement equals and hashCode if you have fields!
| Constructor and Description |
|---|
BBoxSimilarityValueSource(ValueSource bboxValueSource) |
| Modifier and Type | Method and Description |
|---|---|
void |
createWeight(Map context,
IndexSearcher searcher) |
String |
description() |
boolean |
equals(Object o) |
FunctionValues |
getValues(Map context,
LeafReaderContext readerContext) |
int |
hashCode() |
protected abstract double |
score(org.locationtech.spatial4j.shape.Rectangle rect,
AtomicReference<Explanation> exp)
Return a relevancy score.
|
protected abstract String |
similarityDescription()
A comma-separated list of configurable items of the subclass to put into
description(). |
asDoubleValuesSource, asLongValuesSource, getSortField, newContext, toStringpublic BBoxSimilarityValueSource(ValueSource bboxValueSource)
public void createWeight(Map context, IndexSearcher searcher) throws IOException
createWeight in class ValueSourceIOExceptionpublic String description()
description in class ValueSourceprotected abstract String similarityDescription()
description().public FunctionValues getValues(Map context, LeafReaderContext readerContext) throws IOException
getValues in class ValueSourceIOExceptionprotected abstract double score(org.locationtech.spatial4j.shape.Rectangle rect,
AtomicReference<Explanation> exp)
exp is provided then diagnostic information is added.rect - The indexed rectangle; not null.exp - Optional diagnostic holder.public boolean equals(Object o)
equals in class ValueSourcepublic int hashCode()
hashCode in class ValueSourceCopyright © 2000-2017 Apache Software Foundation. All Rights Reserved.