Class ElasticsearchLongFieldCodec
java.lang.Object
org.hibernate.search.backend.elasticsearch.types.codec.impl.AbstractElasticsearchFieldCodec<Long>
org.hibernate.search.backend.elasticsearch.types.codec.impl.ElasticsearchLongFieldCodec
- All Implemented Interfaces:
ElasticsearchFieldCodec<Long>
-
Field Summary
Fields inherited from class org.hibernate.search.backend.elasticsearch.types.codec.impl.AbstractElasticsearchFieldCodec
gson -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondecode(com.google.gson.JsonElement element) com.google.gson.JsonElementcom.google.gson.JsonElementencodeForAggregation(ElasticsearchSearchSyntax searchSyntax, Long value) Encodes a value for inclusion in an aggregation request.booleanisCompatibleWith(ElasticsearchFieldCodec<?> other) Determine whether another codec is compatible with this one, i.e. whether it will encode/decode the information to/from the document in a compatible way.Methods inherited from class org.hibernate.search.backend.elasticsearch.types.codec.impl.AbstractElasticsearchFieldCodec
fromJsonElementToString, fromJsonStringToElementMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.hibernate.search.backend.elasticsearch.types.codec.impl.ElasticsearchFieldCodec
canDecodeArrays, decodeAggregationKey, encodeForMissing
-
Constructor Details
-
ElasticsearchLongFieldCodec
public ElasticsearchLongFieldCodec(com.google.gson.Gson gson)
-
-
Method Details
-
encode
-
encodeForAggregation
public com.google.gson.JsonElement encodeForAggregation(ElasticsearchSearchSyntax searchSyntax, Long value) Description copied from interface:ElasticsearchFieldCodecEncodes a value for inclusion in an aggregation request.- Parameters:
searchSyntax- The search syntax.value- The value to encode.- Returns:
- The encoded value.
-
decode
-
isCompatibleWith
Description copied from interface:ElasticsearchFieldCodecDetermine whether another codec is compatible with this one, i.e. whether it will encode/decode the information to/from the document in a compatible way.- Parameters:
other- AnotherElasticsearchFieldCodec, nevernull.- Returns:
trueif the given codec is compatible.falseotherwise, or when in doubt.
-