Package org.apache.lucene.facet.taxonomy
Class FloatAssociationFacetField
java.lang.Object
org.apache.lucene.document.Field
org.apache.lucene.facet.taxonomy.AssociationFacetField
org.apache.lucene.facet.taxonomy.FloatAssociationFacetField
- All Implemented Interfaces:
IndexableField
Add an instance of this to your
Document to add
a facet label associated with a float. Use TaxonomyFacetSumFloatAssociations to aggregate float values
per facet label at search time.-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.lucene.document.Field
Field.Index, Field.Store, Field.TermVector -
Field Summary
Fields inherited from class org.apache.lucene.facet.taxonomy.AssociationFacetField
assoc, dim, path, TYPE -
Constructor Summary
ConstructorsConstructorDescriptionFloatAssociationFacetField(float assoc, String dim, String... path) Creates this fromdimandpathand a float association -
Method Summary
Modifier and TypeMethodDescriptionstatic floatDecodes a previously encodedfloat.static BytesReffloatToBytesRef(float v) Encodes afloatas a 4-byteBytesRef.toString()Prints a Field for human consumption.Methods inherited from class org.apache.lucene.document.Field
binaryValue, boost, fieldType, name, numericValue, readerValue, setBoost, setBytesValue, setBytesValue, setByteValue, setDoubleValue, setFloatValue, setIntValue, setLongValue, setReaderValue, setShortValue, setStringValue, setTokenStream, stringValue, tokenStream, tokenStreamValue, translateFieldType
-
Constructor Details
-
FloatAssociationFacetField
Creates this fromdimandpathand a float association
-
-
Method Details
-
floatToBytesRef
Encodes afloatas a 4-byteBytesRef. -
bytesRefToFloat
Decodes a previously encodedfloat. -
toString
Description copied from class:FieldPrints a Field for human consumption.- Overrides:
toStringin classAssociationFacetField
-