Class MatchRegionRetriever.StoredFieldsVisitor
java.lang.Object
org.apache.lucene.index.StoredFieldVisitor
org.apache.lucene.search.matchhighlight.MatchRegionRetriever.StoredFieldsVisitor
- All Implemented Interfaces:
Iterable<String>
,MatchRegionRetriever.FieldValueProvider
- Enclosing class:
MatchRegionRetriever
private static class MatchRegionRetriever.StoredFieldsVisitor
extends StoredFieldVisitor
implements MatchRegionRetriever.FieldValueProvider
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.lucene.index.StoredFieldVisitor
StoredFieldVisitor.Status
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate void
void
doubleField
(FieldInfo fieldInfo, double value) Process a double numeric field.void
floatField
(FieldInfo fieldInfo, float value) Process a float numeric field.void
Process a int numeric field.iterator()
void
Process a long numeric field.needsField
(FieldInfo fieldInfo) Hook before processing a field.void
stringField
(FieldInfo fieldInfo, String value) Process a string field.Methods inherited from class org.apache.lucene.index.StoredFieldVisitor
binaryField, binaryField
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Field Details
-
needsField
-
fieldValues
-
-
Constructor Details
-
StoredFieldsVisitor
-
-
Method Details
-
needsField
Description copied from class:StoredFieldVisitor
Hook before processing a field. Before a field is processed, this method is invoked so that subclasses can return aStoredFieldVisitor.Status
representing whether they need that particular field or not, or to stop processing entirely.- Specified by:
needsField
in classStoredFieldVisitor
- Throws:
IOException
-
getValues
- Specified by:
getValues
in interfaceMatchRegionRetriever.FieldValueProvider
- Returns:
- Return a list of values for the provided field name or
null
if the field is not loaded or does not exist for the field.
-
stringField
Description copied from class:StoredFieldVisitor
Process a string field.- Overrides:
stringField
in classStoredFieldVisitor
- Throws:
IOException
-
intField
Description copied from class:StoredFieldVisitor
Process a int numeric field.- Overrides:
intField
in classStoredFieldVisitor
- Throws:
IOException
-
longField
Description copied from class:StoredFieldVisitor
Process a long numeric field.- Overrides:
longField
in classStoredFieldVisitor
- Throws:
IOException
-
floatField
Description copied from class:StoredFieldVisitor
Process a float numeric field.- Overrides:
floatField
in classStoredFieldVisitor
- Throws:
IOException
-
doubleField
Description copied from class:StoredFieldVisitor
Process a double numeric field.- Overrides:
doubleField
in classStoredFieldVisitor
- Throws:
IOException
-
addField
-
iterator
-