Package org.apache.lucene.facet
Class FacetField
java.lang.Object
org.apache.lucene.document.Field
org.apache.lucene.facet.FacetField
- All Implemented Interfaces:
IndexableField
Add an instance of this to your
Document
for every facet label.
NOTE: you must call FacetsConfig.build(Document)
before you add the document to
IndexWriter.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.lucene.document.Field
Field.Store
-
Field Summary
Modifier and TypeFieldDescriptionfinal String
Dimension for this field.final String[]
Path for this field.static final FieldType
Field type used for storing facet values.Fields inherited from class org.apache.lucene.document.Field
fieldsData, name, tokenStream, type
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiontoString()
static void
verifyLabel
(String label) Verifies the label is not null or empty string.Methods inherited from class org.apache.lucene.document.Field
binaryValue, fieldType, getCharSequenceValue, invertableType, name, numericValue, readerValue, setBytesValue, setBytesValue, setByteValue, setDoubleValue, setFloatValue, setIntValue, setLongValue, setReaderValue, setShortValue, setStringValue, setTokenStream, storedValue, stringValue, tokenStream, tokenStreamValue
-
Field Details
-
TYPE
Field type used for storing facet values. Actual field type used for indexing is determined inFacetsConfig.build(TaxonomyWriter, Document)
-
dim
Dimension for this field. -
path
Path for this field.
-
-
Constructor Details
-
FacetField
Creates the this fromdim
andpath
.
-
-
Method Details