Class LuceneInstantFieldCodec
- java.lang.Object
-
- org.hibernate.search.backend.lucene.types.codec.impl.AbstractLuceneNumericFieldCodec<Instant,Long>
-
- org.hibernate.search.backend.lucene.types.codec.impl.LuceneInstantFieldCodec
-
- All Implemented Interfaces:
LuceneFieldCodec<Instant>,LuceneStandardFieldCodec<Instant,Long>
public final class LuceneInstantFieldCodec extends AbstractLuceneNumericFieldCodec<Instant,Long>
-
-
Constructor Summary
Constructors Constructor Description LuceneInstantFieldCodec(Indexing indexing, DocValues docValues, Storage storage, Instant indexNullAsValue)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Instantdecode(Long encoded)Instantdecode(org.apache.lucene.index.IndexableField field)Extract the value from the given stored field.Longencode(Instant value)Encode the given value.LuceneNumericDomain<Long>getDomain()-
Methods inherited from class org.hibernate.search.backend.lucene.types.codec.impl.AbstractLuceneNumericFieldCodec
addToDocument, isCompatibleWith
-
-
-
-
Method Detail
-
decode
public Instant decode(org.apache.lucene.index.IndexableField field)
Description copied from interface:LuceneFieldCodecExtract the value from the given stored field.Typically used in projections.
- Parameters:
field- The document field. Nevernull.- Returns:
- The decoded value.
-
encode
public Long encode(Instant value)
Description copied from interface:LuceneStandardFieldCodecEncode the given value.Useful for predicates and sorts in particular.
- Parameters:
value- The value to encode.
-
decode
public Instant decode(Long encoded)
- Specified by:
decodein classAbstractLuceneNumericFieldCodec<Instant,Long>
-
getDomain
public LuceneNumericDomain<Long> getDomain()
- Specified by:
getDomainin classAbstractLuceneNumericFieldCodec<Instant,Long>
-
-