Class NumberSerializer.BigDecimalAsStringSerializer
java.lang.Object
com.fasterxml.jackson.databind.JsonSerializer<Object>
com.fasterxml.jackson.databind.ser.std.StdSerializer<Object>
com.fasterxml.jackson.databind.ser.std.ToStringSerializerBase
com.fasterxml.jackson.databind.ser.std.NumberSerializer.BigDecimalAsStringSerializer
- All Implemented Interfaces:
JsonFormatVisitable,SchemaAware,Serializable
- Enclosing class:
NumberSerializer
-
Nested Class Summary
Nested classes/interfaces inherited from class com.fasterxml.jackson.databind.JsonSerializer
JsonSerializer.None -
Field Summary
FieldsModifier and TypeFieldDescription(package private) static final NumberSerializer.BigDecimalAsStringSerializerFields inherited from class com.fasterxml.jackson.databind.ser.std.StdSerializer
_handledType -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected boolean_verifyBigDecimalRange(com.fasterxml.jackson.core.JsonGenerator gen, BigDecimal value) booleanisEmpty(SerializerProvider prov, Object value) Method called to check whether given serializable value is considered "empty" value (for purposes of suppressing serialization of empty values).voidserialize(Object value, com.fasterxml.jackson.core.JsonGenerator gen, SerializerProvider provider) Method that can be called to ask implementation to serialize values of type this serializer handles.valueToString(Object value) Methods inherited from class com.fasterxml.jackson.databind.ser.std.ToStringSerializerBase
acceptJsonFormatVisitor, getSchema, serializeWithTypeMethods inherited from class com.fasterxml.jackson.databind.ser.std.StdSerializer
_neitherNull, _nonEmpty, createSchemaNode, createSchemaNode, findAnnotatedContentSerializer, findContextualConvertingSerializer, findConvertingContentSerializer, findFormatFeature, findFormatOverrides, findIncludeOverrides, findPropertyFilter, getSchema, handledType, isDefaultSerializer, visitArrayFormat, visitArrayFormat, visitFloatFormat, visitIntFormat, visitIntFormat, visitStringFormat, visitStringFormat, wrapAndThrow, wrapAndThrowMethods inherited from class com.fasterxml.jackson.databind.JsonSerializer
getDelegatee, isEmpty, isUnwrappingSerializer, properties, replaceDelegatee, unwrappingSerializer, usesObjectId, withFilterId, withIgnoredProperties
-
Field Details
-
BD_INSTANCE
-
-
Constructor Details
-
BigDecimalAsStringSerializer
public BigDecimalAsStringSerializer()
-
-
Method Details
-
isEmpty
Description copied from class:JsonSerializerMethod called to check whether given serializable value is considered "empty" value (for purposes of suppressing serialization of empty values).Default implementation will consider only null values to be empty.
NOTE: replaces
JsonSerializer.isEmpty(Object), which was deprecated in 2.5- Overrides:
isEmptyin classToStringSerializerBase
-
serialize
public void serialize(Object value, com.fasterxml.jackson.core.JsonGenerator gen, SerializerProvider provider) throws IOException Description copied from class:JsonSerializerMethod that can be called to ask implementation to serialize values of type this serializer handles.- Overrides:
serializein classToStringSerializerBase- Parameters:
value- Value to serialize; can not be null.gen- Generator used to output resulting Json contentprovider- Provider that can be used to get serializers for serializing Objects value contains, if any.- Throws:
IOException
-
valueToString
- Specified by:
valueToStringin classToStringSerializerBase
-
_verifyBigDecimalRange
protected boolean _verifyBigDecimalRange(com.fasterxml.jackson.core.JsonGenerator gen, BigDecimal value) throws IOException - Throws:
IOException
-