Class ElasticsearchBigDecimalFieldCodec
- java.lang.Object
-
- org.hibernate.search.backend.elasticsearch.types.codec.impl.ElasticsearchBigDecimalFieldCodec
-
- All Implemented Interfaces:
ElasticsearchFieldCodec<BigDecimal>
public class ElasticsearchBigDecimalFieldCodec extends Object implements ElasticsearchFieldCodec<BigDecimal>
-
-
Constructor Summary
Constructors Constructor Description ElasticsearchBigDecimalFieldCodec(int decimalScale)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BigDecimaldecode(com.google.gson.JsonElement element)com.google.gson.JsonElementencode(BigDecimal value)booleanisCompatibleWith(ElasticsearchFieldCodec<?> obj)Determine whether another codec is compatible with this one, i.e.BigDecimalscalingFactor()StringtoString()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.hibernate.search.backend.elasticsearch.types.codec.impl.ElasticsearchFieldCodec
decodeAggregationKey, encodeForAggregation, encodeForMissing
-
-
-
-
Method Detail
-
encode
public com.google.gson.JsonElement encode(BigDecimal value)
- Specified by:
encodein interfaceElasticsearchFieldCodec<BigDecimal>
-
decode
public BigDecimal decode(com.google.gson.JsonElement element)
- Specified by:
decodein interfaceElasticsearchFieldCodec<BigDecimal>
-
isCompatibleWith
public boolean isCompatibleWith(ElasticsearchFieldCodec<?> obj)
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.- Specified by:
isCompatibleWithin interfaceElasticsearchFieldCodec<BigDecimal>- Parameters:
obj- AnotherElasticsearchFieldCodec, nevernull.- Returns:
trueif the given codec is compatible.falseotherwise, or when in doubt.
-
scalingFactor
public BigDecimal scalingFactor()
-
-