public abstract class ValueSource
extends java.lang.Object
| Constructor and Description |
|---|
ValueSource() |
| Modifier and Type | Method and Description |
|---|---|
DoubleValuesSource |
asDoubleValuesSource()
Expose this ValueSource as a DoubleValuesSource
|
LongValuesSource |
asLongValuesSource()
Expose this ValueSource as a LongValuesSource
|
void |
createWeight(java.util.Map context,
IndexSearcher searcher)
Implementations should propagate createWeight to sub-ValueSources which can optionally store
weight info in the context.
|
abstract java.lang.String |
description()
description of field, used in explain()
|
abstract boolean |
equals(java.lang.Object o) |
static ValueSource |
fromDoubleValuesSource(DoubleValuesSource in) |
SortField |
getSortField(boolean reverse)
EXPERIMENTAL: This method is subject to change.
|
abstract FunctionValues |
getValues(java.util.Map context,
LeafReaderContext readerContext)
Gets the values for this reader and the context that was previously
passed to createWeight().
|
abstract int |
hashCode() |
static java.util.Map |
newContext(IndexSearcher searcher)
Returns a new non-threadsafe context map.
|
java.lang.String |
toString() |
public abstract FunctionValues getValues(java.util.Map context, LeafReaderContext readerContext) throws java.io.IOException
java.io.IOExceptionpublic abstract boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic abstract int hashCode()
hashCode in class java.lang.Objectpublic abstract java.lang.String description()
public java.lang.String toString()
toString in class java.lang.Objectpublic void createWeight(java.util.Map context,
IndexSearcher searcher)
throws java.io.IOException
java.io.IOExceptionpublic static java.util.Map newContext(IndexSearcher searcher)
public LongValuesSource asLongValuesSource()
public DoubleValuesSource asDoubleValuesSource()
public static ValueSource fromDoubleValuesSource(DoubleValuesSource in)
public SortField getSortField(boolean reverse)
Get the SortField for this ValueSource. Uses the getValues(java.util.Map, org.apache.lucene.index.LeafReaderContext)
to populate the SortField.
reverse - true if this is a reverse sort.SortField for the ValueSourceCopyright © 2000–2025 The Apache Software Foundation. All rights reserved.