Uses of Class
org.codehaus.jackson.map.JsonSerializer
Packages that use JsonSerializer
Package
Description
Contains basic mapper (conversion) functionality that
allows for converting between regular streaming json content and
Java objects (beans or Tree Model: support for both is via
ObjectMapper
class, as well
as convenience methods included in
JsonParser
Contains extended support for "external" packages: things that
may or may not be present in runtime environment, but that are
commonly enough used so that explicit support can be added.
Functionality needed for Bean introspection, required for detecting
accessors and mutators for Beans, as well as locating and handling
method annotations.
Package that contains classes and interfaces to help implement
custom extension
Module
s
(which are registered using
ObjectMapper.registerModule(org.codehaus.jackson.map.Module)
.Contains implementation classes of serialization part of
data binding.
Contains implementation classes of serialization part of
data binding.
Package that contains XML Compatibility functionality for Jackson, such
as handlers for JAXB annotations
-
Uses of JsonSerializer in org.codehaus.jackson.map
Subclasses of JsonSerializer in org.codehaus.jackson.mapModifier and TypeClassDescriptionstatic class
This marker class is only to be used with annotations, to indicate that no serializer is configured.Methods in org.codehaus.jackson.map that return JsonSerializerModifier and TypeMethodDescriptionContextualSerializer.createContextual
(SerializationConfig config, BeanProperty property) Method called to see if a different (or differently configured) serializer is needed to serialize values of specified property.abstract JsonSerializer<Object>
SerializerFactory.createKeySerializer
(SerializationConfig config, JavaType baseType, BeanProperty property) Method called to create serializer to use for serializing JSON property names (which must be output asJsonToken.FIELD_NAME
) for Map that has specified declared key type, and is for specified property (or, if property is null, as root value)abstract JsonSerializer<Object>
SerializerFactory.createSerializer
(SerializationConfig config, JavaType baseType, BeanProperty property) Method called to create (or, for immutable serializers, reuse) a serializer for given type.final JsonSerializer<Object>
SerializerFactory.createSerializer
(JavaType type, SerializationConfig config) Deprecated.Since 1.7, call variant with more argumentsSerializers.Base.findArraySerializer
(SerializationConfig config, ArrayType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.findArraySerializer
(SerializationConfig config, ArrayType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Method called by serialization framework first time a serializer is needed for specified array type.Serializers.Base.findCollectionLikeSerializer
(SerializationConfig config, CollectionLikeType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.findCollectionLikeSerializer
(SerializationConfig config, CollectionLikeType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.Base.findCollectionSerializer
(SerializationConfig config, CollectionType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.findCollectionSerializer
(SerializationConfig config, CollectionType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) abstract JsonSerializer<Object>
SerializerProvider.findKeySerializer
(JavaType keyType, BeanProperty property) Method called to get the serializer to use for serializing non-null Map keys.Serializers.Base.findMapLikeSerializer
(SerializationConfig config, MapLikeType type, BeanDescription beanDesc, BeanProperty property, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.findMapLikeSerializer
(SerializationConfig config, MapLikeType type, BeanDescription beanDesc, BeanProperty property, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.Base.findMapSerializer
(SerializationConfig config, MapType type, BeanDescription beanDesc, BeanProperty property, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.findMapSerializer
(SerializationConfig config, MapType type, BeanDescription beanDesc, BeanProperty property, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.Base.findSerializer
(SerializationConfig config, JavaType type, BeanDescription beanDesc, BeanProperty property) Serializers.findSerializer
(SerializationConfig config, JavaType type, BeanDescription beanDesc, BeanProperty property) Method called by serialization framework first time a serializer is needed for specified type, which is not of a container type (for which other methods are called).final JsonSerializer<Object>
SerializerProvider.findTypedValueSerializer
(Class<?> valueType, boolean cache) Deprecated.As of version 1.7, use version that exposes property object instead of just its type (needed for contextual serializers)abstract JsonSerializer<Object>
SerializerProvider.findTypedValueSerializer
(Class<?> valueType, boolean cache, BeanProperty property) Method called to locate regular serializer, matching type serializer, and if both found, wrap them in a serializer that calls both in correct sequence.final JsonSerializer<Object>
SerializerProvider.findTypedValueSerializer
(JavaType valueType, boolean cache) Deprecated.As of version 1.7, use version that exposes property object instead of just its type (needed for contextual serializers)abstract JsonSerializer<Object>
SerializerProvider.findTypedValueSerializer
(JavaType valueType, boolean cache, BeanProperty property) Method called to locate regular serializer, matching type serializer, and if both found, wrap them in a serializer that calls both in correct sequence.final JsonSerializer<Object>
SerializerProvider.findValueSerializer
(Class<?> runtimeType) Deprecated.As of version 1.7, use version that exposes property object instead of just its type (needed for contextual serializers)abstract JsonSerializer<Object>
SerializerProvider.findValueSerializer
(Class<?> runtimeType, BeanProperty property) Method called to get hold of a serializer for a value of given type; or if no such serializer can be found, a default handler (which may do a best-effort generic serialization or just simply throw an exception when invoked).final JsonSerializer<Object>
SerializerProvider.findValueSerializer
(JavaType serializationType) Deprecated.As of version 1.7, use version that exposes property object instead of just its type (needed for contextual serializers)abstract JsonSerializer<Object>
SerializerProvider.findValueSerializer
(JavaType serializationType, BeanProperty property) Similar toSerializerProvider.findValueSerializer(Class)
, but takes full generics-aware type instead of raw class.final JsonSerializer<Object>
SerializerProvider.getKeySerializer()
Deprecated.As of version 1.7, use version that exposes property object instead of just its type (needed for contextual serializers)final JsonSerializer<Object>
SerializerProvider.getKeySerializer
(JavaType valueType, BeanProperty property) Deprecated.As of version 1.8abstract JsonSerializer<Object>
SerializerProvider.getNullKeySerializer()
Method called to get the serializer to use for serializing Map keys that are nulls: this is needed since JSON does not allow any non-String value as key, including null.abstract JsonSerializer<Object>
SerializerProvider.getNullValueSerializer()
Method called to get the serializer to use for serializing values (root level, Array members or List field values) that are nulls.abstract JsonSerializer<Object>
SerializerProvider.getUnknownTypeSerializer
(Class<?> unknownType) Method called to get the serializer to use if provider can not determine an actual type-specific serializer to use; typically when none ofSerializerFactory
instances are able to construct a serializer.abstract JsonSerializer<?>
HandlerInstantiator.serializerInstance
(SerializationConfig config, Annotated annotated, Class<? extends JsonSerializer<?>> serClass) Method called to get an instance of serializer of specified type.SerializationConfig.serializerInstance
(Annotated annotated, Class<? extends JsonSerializer<?>> serClass) JsonSerializer.unwrappingSerializer()
Method that will return serializer instance that produces "unwrapped" serialization, if applicable for type being serialized (which is the case for some serializers that produce JSON Objects as output).Methods in org.codehaus.jackson.map that return types with arguments of type JsonSerializerModifier and TypeMethodDescriptionClass<? extends JsonSerializer<?>>
AnnotationIntrospector.findContentSerializer
(Annotated am) Method for getting a serializer definition for content (values) of associatedCollection
,array
orMap
property.Class<? extends JsonSerializer<?>>
AnnotationIntrospector.Pair.findContentSerializer
(Annotated a) Class<? extends JsonSerializer<?>>
AnnotationIntrospector.findKeySerializer
(Annotated am) Method for getting a serializer definition for keys of associatedMap
property.Class<? extends JsonSerializer<?>>
AnnotationIntrospector.Pair.findKeySerializer
(Annotated a) Methods in org.codehaus.jackson.map with parameters of type JsonSerializerModifier and TypeMethodDescriptionSerializers.Base.findArraySerializer
(SerializationConfig config, ArrayType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.findArraySerializer
(SerializationConfig config, ArrayType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Method called by serialization framework first time a serializer is needed for specified array type.Serializers.Base.findCollectionLikeSerializer
(SerializationConfig config, CollectionLikeType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.findCollectionLikeSerializer
(SerializationConfig config, CollectionLikeType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.Base.findCollectionSerializer
(SerializationConfig config, CollectionType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.findCollectionSerializer
(SerializationConfig config, CollectionType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.Base.findMapLikeSerializer
(SerializationConfig config, MapLikeType type, BeanDescription beanDesc, BeanProperty property, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.findMapLikeSerializer
(SerializationConfig config, MapLikeType type, BeanDescription beanDesc, BeanProperty property, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.Base.findMapSerializer
(SerializationConfig config, MapType type, BeanDescription beanDesc, BeanProperty property, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Serializers.findMapSerializer
(SerializationConfig config, MapType type, BeanDescription beanDesc, BeanProperty property, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) abstract void
SerializerProvider.setDefaultKeySerializer
(JsonSerializer<Object> ks) Method that can be used to specify serializer to use for serializing all non-null JSON property names, unless more specific key serializer is found (i.e.abstract void
SerializerProvider.setNullKeySerializer
(JsonSerializer<Object> nks) Method that can be used to specify serializer that will be used to write JSON property names matching null keys for Java Maps (which will throw an exception if try write such property name)abstract void
SerializerProvider.setNullValueSerializer
(JsonSerializer<Object> nvs) Method that can be used to specify serializer that will be used to write JSON values matching Java null values instead of default one (which simply writes JSON null)Method parameters in org.codehaus.jackson.map with type arguments of type JsonSerializerModifier and TypeMethodDescriptionabstract JsonSerializer<?>
HandlerInstantiator.serializerInstance
(SerializationConfig config, Annotated annotated, Class<? extends JsonSerializer<?>> serClass) Method called to get an instance of serializer of specified type.SerializationConfig.serializerInstance
(Annotated annotated, Class<? extends JsonSerializer<?>> serClass) -
Uses of JsonSerializer in org.codehaus.jackson.map.ext
Subclasses of JsonSerializer in org.codehaus.jackson.map.extModifier and TypeClassDescriptionstatic class
class
static final class
static final class
protected static class
static final class
static final class
Methods in org.codehaus.jackson.map.ext that return JsonSerializerModifier and TypeMethodDescriptionOptionalHandlerFactory.findSerializer
(SerializationConfig config, JavaType type) Methods in org.codehaus.jackson.map.ext that return types with arguments of type JsonSerializerModifier and TypeMethodDescriptionCollection<Map.Entry<Class<?>,
JsonSerializer<?>>> CoreXMLSerializers.provide()
Collection<Map.Entry<Class<?>,
JsonSerializer<?>>> JodaSerializers.provide()
-
Uses of JsonSerializer in org.codehaus.jackson.map.introspect
Methods in org.codehaus.jackson.map.introspect that return types with arguments of type JsonSerializerModifier and TypeMethodDescriptionClass<? extends JsonSerializer<?>>
JacksonAnnotationIntrospector.findContentSerializer
(Annotated a) Class<? extends JsonSerializer<?>>
JacksonAnnotationIntrospector.findKeySerializer
(Annotated a) -
Uses of JsonSerializer in org.codehaus.jackson.map.module
Fields in org.codehaus.jackson.map.module with type parameters of type JsonSerializerModifier and TypeFieldDescriptionprotected HashMap<ClassKey,
JsonSerializer<?>> SimpleSerializers._classMappings
Class-based mappings that are used both for exact and sub-class matches.protected HashMap<ClassKey,
JsonSerializer<?>> SimpleSerializers._interfaceMappings
Interface-based matches.Methods in org.codehaus.jackson.map.module that return JsonSerializerModifier and TypeMethodDescriptionprotected JsonSerializer<?>
SimpleSerializers._findInterfaceMapping
(Class<?> cls, ClassKey key) SimpleSerializers.findArraySerializer
(SerializationConfig config, ArrayType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) SimpleSerializers.findCollectionLikeSerializer
(SerializationConfig config, CollectionLikeType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) SimpleSerializers.findCollectionSerializer
(SerializationConfig config, CollectionType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) SimpleSerializers.findMapLikeSerializer
(SerializationConfig config, MapLikeType type, BeanDescription beanDesc, BeanProperty property, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) SimpleSerializers.findMapSerializer
(SerializationConfig config, MapType type, BeanDescription beanDesc, BeanProperty property, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) SimpleSerializers.findSerializer
(SerializationConfig config, JavaType type, BeanDescription beanDesc, BeanProperty property) Methods in org.codehaus.jackson.map.module with parameters of type JsonSerializerModifier and TypeMethodDescription<T> SimpleModule
SimpleModule.addKeySerializer
(Class<? extends T> type, JsonSerializer<T> ser) <T> SimpleModule
SimpleModule.addSerializer
(Class<? extends T> type, JsonSerializer<T> ser) SimpleModule.addSerializer
(JsonSerializer<?> ser) <T> void
SimpleSerializers.addSerializer
(Class<? extends T> type, JsonSerializer<T> ser) void
SimpleSerializers.addSerializer
(JsonSerializer<?> ser) Method for adding given serializer for type thathandledType()
specifies (which MUST return a non-null class; and can NOT beObject
, as a sanity check).SimpleSerializers.findArraySerializer
(SerializationConfig config, ArrayType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) SimpleSerializers.findCollectionLikeSerializer
(SerializationConfig config, CollectionLikeType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) SimpleSerializers.findCollectionSerializer
(SerializationConfig config, CollectionType type, BeanDescription beanDesc, BeanProperty property, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) SimpleSerializers.findMapLikeSerializer
(SerializationConfig config, MapLikeType type, BeanDescription beanDesc, BeanProperty property, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) SimpleSerializers.findMapSerializer
(SerializationConfig config, MapType type, BeanDescription beanDesc, BeanProperty property, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) -
Uses of JsonSerializer in org.codehaus.jackson.map.ser
Subclasses of JsonSerializer in org.codehaus.jackson.map.serModifier and TypeClassDescriptionclass
Serializer class that can serialize arbitrary bean objectsclass
Deprecated.Since 1.9 useEnumSerializer
class
Deprecated.Since 1.9 useMapSerializer
class
Deprecated.Since 1.9 useSerializerBase
instead.class
Deprecated.Since 1.9 useSerializerBase
final class
Deprecated.Since 1.9 useStdKeySerializer
insteadstatic final class
Serializer used for primitive boolean, as well as java.util.Boolean wrapper type.static final class
Deprecated.Since 1.9, useDateSerializer
insteadstatic final class
This is the special serializer for regularDouble
s (and primitive doubles)static final class
static final class
This is the special serializer for regularInteger
s (and primitive ints)static final class
Similar toStdSerializers.IntegerSerializer
, but will not cast to Integer: instead, cast is toNumber
, and conversion is by callingNumber.intValue()
.static final class
static final class
As a fallback, we may need to use this serializer for other types ofNumber
s (custom types).static final class
Deprecated.Since 1.9, useDateSerializer
insteadstatic final class
Deprecated.Since 1.9, useDateSerializer
insteadstatic final class
Compared to regularStdSerializers.UtilDateSerializer
, we do use String representation here.static final class
static final class
Deprecated.Since 1.9, useStringSerializer
insteadstatic final class
Deprecated.Since 1.9, useDateSerializer
insteadfinal class
Deprecated.Since 1.9 useToStringSerializer
Fields in org.codehaus.jackson.map.ser declared as JsonSerializerModifier and TypeFieldDescriptionprotected JsonSerializer<?>
CustomSerializerFactory._enumSerializerOverride
And for Enum handling we may specify a single default serializer to use, regardless of actual enumeration.protected JsonSerializer<Object>
StdSerializerProvider._keySerializer
Serializer used to output non-null keys of Maps (which will get output as JSON Objects), if not null; if null, us the standard default key serializer.protected JsonSerializer<Object>
StdSerializerProvider._nullKeySerializer
Serializer used to (try to) output a null key, due to an entry ofMap
having null key.protected JsonSerializer<Object>
StdSerializerProvider._nullValueSerializer
Serializer used to output a null value.protected final JsonSerializer<Object>
BeanPropertyWriter._serializer
Serializer to use for writing out the value: null if it can not be known statically; non-null if it can.protected JsonSerializer<Object>
StdSerializerProvider._unknownTypeSerializer
Serializer that gets called for values of types for which no serializers can be constructed.static final JsonSerializer<Object>
StdSerializerProvider.DEFAULT_KEY_SERIALIZER
Deprecated.Since 1.9, useStdKeySerializers
insteadstatic final JsonSerializer<Object>
StdSerializerProvider.DEFAULT_NULL_KEY_SERIALIZER
static final JsonSerializer<Object>
StdSerializerProvider.DEFAULT_UNKNOWN_SERIALIZER
Fields in org.codehaus.jackson.map.ser with type parameters of type JsonSerializerModifier and TypeFieldDescriptionprotected static final HashMap<String,
JsonSerializer<?>> BasicSerializerFactory._arraySerializers
protected static final HashMap<String,
JsonSerializer<?>> BasicSerializerFactory._concrete
Since these are all JDK classes, we shouldn't have to worry about ClassLoader used to load them.protected static final HashMap<String,
Class<? extends JsonSerializer<?>>> BasicSerializerFactory._concreteLazy
Actually it may not make much sense to eagerly instantiate all kinds of serializers: so this Map actually contains class references, not instancesprotected HashMap<ClassKey,
JsonSerializer<?>> CustomSerializerFactory._directClassMappings
Direct mappings that are only used for exact class type matches, but not for sub-class checks.protected HashMap<ClassKey,
JsonSerializer<?>> CustomSerializerFactory._interfaceMappings
And finally interface-based matches.protected HashMap<ClassKey,
JsonSerializer<?>> CustomSerializerFactory._transitiveClassMappings
And then class-based mappings that are used both for exact and sub-class matches.Methods in org.codehaus.jackson.map.ser that return JsonSerializerModifier and TypeMethodDescriptionprotected JsonSerializer<Object>
StdSerializerProvider._createAndCacheUntypedSerializer
(Class<?> type, BeanProperty property) Method that will try to construct a value serializer; and if one is successfully created, cache it for reuse.protected JsonSerializer<Object>
StdSerializerProvider._createAndCacheUntypedSerializer
(JavaType type, BeanProperty property) protected JsonSerializer<Object>
StdSerializerProvider._createUntypedSerializer
(JavaType type, BeanProperty property) protected JsonSerializer<Object>
BeanPropertyWriter._findAndAddDynamic
(PropertySerializerMap map, Class<?> type, SerializerProvider provider) protected JsonSerializer<Object>
StdSerializerProvider._findExplicitUntypedSerializer
(Class<?> runtimeType, BeanProperty property) Method that will try to find a serializer, either from cache or by constructing one; but will not return an "unknown" serializer if this can not be done but rather returns null.protected JsonSerializer<?>
CustomSerializerFactory._findInterfaceMapping
(Class<?> cls, ClassKey key) protected JsonSerializer<Object>
StdSerializerProvider._handleContextualResolvable
(JsonSerializer<Object> ser, BeanProperty property) BeanSerializerBuilder.build()
Method called to createBeanSerializer
instance with all accumulated information.protected JsonSerializer<?>
BasicSerializerFactory.buildArraySerializer
(SerializationConfig config, ArrayType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Helper method that handles configuration details when constructing serializers forObject[]
(and subtypes, except for String).protected JsonSerializer<?>
BasicSerializerFactory.buildCollectionLikeSerializer
(SerializationConfig config, CollectionLikeType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Helper method that handles configuration details when constructing serializers for Collection and Collection-like types.protected JsonSerializer<?>
BasicSerializerFactory.buildCollectionSerializer
(SerializationConfig config, CollectionType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Helper method that handles configuration details when constructing serializers forList
types that support efficient by-index accessBasicSerializerFactory.buildContainerSerializer
(SerializationConfig config, JavaType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping) protected JsonSerializer<?>
BasicSerializerFactory.buildEnumMapSerializer
(SerializationConfig config, JavaType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Helper method that handles configuration details when constructing serializers forEnumMap
types.protected JsonSerializer<?>
BasicSerializerFactory.buildEnumSetSerializer
(SerializationConfig config, JavaType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) protected JsonSerializer<?>
BasicSerializerFactory.buildIterableSerializer
(SerializationConfig config, JavaType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping) protected JsonSerializer<?>
BasicSerializerFactory.buildIteratorSerializer
(SerializationConfig config, JavaType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping) protected JsonSerializer<?>
BasicSerializerFactory.buildMapLikeSerializer
(SerializationConfig config, MapLikeType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Helper method that handles configuration details when constructing serializers for all "Map-like" types; both ones that implementMap
and ones that do not (but that have been indicated to behave like Maps).protected JsonSerializer<?>
BasicSerializerFactory.buildMapSerializer
(SerializationConfig config, MapType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Helper method that handles configuration details when constructing serializers forMap
types.protected JsonSerializer<Object>
BeanSerializerFactory.constructBeanSerializer
(SerializationConfig config, BasicBeanDescription beanDesc, BeanProperty property) Method called to construct serializer for serializing specified bean type.BeanSerializerFactory.createKeySerializer
(SerializationConfig config, JavaType type, BeanProperty property) abstract JsonSerializer<Object>
BasicSerializerFactory.createSerializer
(SerializationConfig config, JavaType type, BeanProperty property) BeanSerializerFactory.createSerializer
(SerializationConfig config, JavaType origType, BeanProperty property) Main serializer constructor method.CustomSerializerFactory.createSerializer
(SerializationConfig config, JavaType type, BeanProperty property) BeanSerializerFactory.findBeanSerializer
(SerializationConfig config, JavaType type, BasicBeanDescription beanDesc, BeanProperty property) Method that will try to construct aBeanSerializer
for given class.protected static JsonSerializer<Object>
BasicSerializerFactory.findContentSerializer
(SerializationConfig config, Annotated a, BeanProperty property) protected JsonSerializer<?>
CustomSerializerFactory.findCustomSerializer
(Class<?> type, SerializationConfig config) protected static JsonSerializer<Object>
BasicSerializerFactory.findKeySerializer
(SerializationConfig config, Annotated a, BeanProperty property) StdSerializerProvider.findKeySerializer
(JavaType keyType, BeanProperty property) final JsonSerializer<?>
BasicSerializerFactory.findSerializerByAddonType
(SerializationConfig config, JavaType javaType, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping) Reflection-based serialized find method, which checks if given class implements one of recognized "add-on" interfaces.final JsonSerializer<?>
BasicSerializerFactory.findSerializerByLookup
(JavaType type, SerializationConfig config, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping) Method that will use fast lookup (and identity comparison) methods to see if we know serializer to use for given type.final JsonSerializer<?>
BasicSerializerFactory.findSerializerByPrimaryType
(JavaType type, SerializationConfig config, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping) Method for checking if we can determine serializer to use based on set of known primary types, checking for set of known base types (exact matches having been compared against withfindSerializerByLookup
).protected JsonSerializer<Object>
BasicSerializerFactory.findSerializerFromAnnotation
(SerializationConfig config, Annotated a, BeanProperty property) Helper method called to check if a class or method has an annotation (@link org.codehaus.jackson.map.ser.JsonSerialize#using) that tells the class to use for serialization.StdSerializerProvider.findTypedValueSerializer
(Class<?> valueType, boolean cache, BeanProperty property) StdSerializerProvider.findTypedValueSerializer
(JavaType valueType, boolean cache, BeanProperty property) StdSerializerProvider.findValueSerializer
(Class<?> valueType, BeanProperty property) StdSerializerProvider.findValueSerializer
(JavaType valueType, BeanProperty property) This variant was added in 1.5, to allow for efficient access using full structured types, not just classes.StdSerializerProvider.getNullKeySerializer()
final JsonSerializer<?>
BasicSerializerFactory.getNullSerializer()
StdSerializerProvider.getNullValueSerializer()
BeanPropertyWriter.getSerializer()
StdSerializerProvider.getUnknownTypeSerializer
(Class<?> unknownType) BeanSerializerModifier.modifySerializer
(SerializationConfig config, BasicBeanDescription beanDesc, JsonSerializer<?> serializer) Method called byBeanSerializerFactory
after constructing default bean serializer instance with properties collected and ordered earlier.BeanSerializer.unwrappingSerializer()
Methods in org.codehaus.jackson.map.ser with parameters of type JsonSerializerModifier and TypeMethodDescriptionprotected JsonSerializer<Object>
StdSerializerProvider._handleContextualResolvable
(JsonSerializer<Object> ser, BeanProperty property) <T> void
CustomSerializerFactory.addGenericMapping
(Class<? extends T> type, JsonSerializer<T> ser) Method used to add a generic (transitive) mapping from specified class or its sub-classes into a serializer.<T> void
CustomSerializerFactory.addSpecificMapping
(Class<? extends T> forClass, JsonSerializer<T> ser) Method used to add a mapping from specific type -- and only that type -- to specified serializer.protected JsonSerializer<?>
BasicSerializerFactory.buildArraySerializer
(SerializationConfig config, ArrayType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Helper method that handles configuration details when constructing serializers forObject[]
(and subtypes, except for String).protected JsonSerializer<?>
BasicSerializerFactory.buildCollectionLikeSerializer
(SerializationConfig config, CollectionLikeType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Helper method that handles configuration details when constructing serializers for Collection and Collection-like types.protected JsonSerializer<?>
BasicSerializerFactory.buildCollectionSerializer
(SerializationConfig config, CollectionType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Helper method that handles configuration details when constructing serializers forList
types that support efficient by-index accessprotected JsonSerializer<?>
BasicSerializerFactory.buildEnumMapSerializer
(SerializationConfig config, JavaType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Helper method that handles configuration details when constructing serializers forEnumMap
types.protected JsonSerializer<?>
BasicSerializerFactory.buildEnumSetSerializer
(SerializationConfig config, JavaType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) protected JsonSerializer<?>
BasicSerializerFactory.buildMapLikeSerializer
(SerializationConfig config, MapLikeType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Helper method that handles configuration details when constructing serializers for all "Map-like" types; both ones that implementMap
and ones that do not (but that have been indicated to behave like Maps).protected JsonSerializer<?>
BasicSerializerFactory.buildMapSerializer
(SerializationConfig config, MapType type, BasicBeanDescription beanDesc, BeanProperty property, boolean staticTyping, JsonSerializer<Object> keySerializer, TypeSerializer elementTypeSerializer, JsonSerializer<Object> elementValueSerializer) Helper method that handles configuration details when constructing serializers forMap
types.protected BeanPropertyWriter
PropertyBuilder.buildWriter
(String name, JavaType declaredType, JsonSerializer<Object> ser, TypeSerializer typeSer, TypeSerializer contentTypeSer, AnnotatedMember am, boolean defaultUseStaticTyping) BeanSerializerModifier.modifySerializer
(SerializationConfig config, BasicBeanDescription beanDesc, JsonSerializer<?> serializer) Method called byBeanSerializerFactory
after constructing default bean serializer instance with properties collected and ordered earlier.void
StdSerializerProvider.setDefaultKeySerializer
(JsonSerializer<Object> ks) void
CustomSerializerFactory.setEnumSerializer
(JsonSerializer<?> enumSer) Method that can be used to force specified serializer to be used for serializing all Enum instances.void
StdSerializerProvider.setNullKeySerializer
(JsonSerializer<Object> nks) void
StdSerializerProvider.setNullValueSerializer
(JsonSerializer<Object> nvs) BeanPropertyWriter.withSerializer
(JsonSerializer<Object> ser) Method that will construct and return a new writer that has same properties as this writer, but uses specified serializer instead of currently configured one (if any).Constructors in org.codehaus.jackson.map.ser with parameters of type JsonSerializerModifierConstructorDescriptionBeanPropertyWriter
(AnnotatedMember member, Annotations contextAnnotations, String name, JavaType declaredType, JsonSerializer<Object> ser, TypeSerializer typeSer, JavaType serType, Method m, Field f, boolean suppressNulls, Object suppressableValue) BeanPropertyWriter
(AnnotatedMember member, Annotations contextAnnotations, SerializedString name, JavaType declaredType, JsonSerializer<Object> ser, TypeSerializer typeSer, JavaType serType, Method m, Field f, boolean suppressNulls, Object suppressableValue) protected
BeanPropertyWriter
(BeanPropertyWriter base, JsonSerializer<Object> ser) "Copy constructor" to be used by filtering sub-classesprotected
MapSerializer
(HashSet<String> ignoredEntries, JavaType keyType, JavaType valueType, boolean valueTypeIsStatic, TypeSerializer vts, JsonSerializer<Object> keySerializer, BeanProperty property) Deprecated.As of 1.8, use version that takes valueSerializerprotected
MapSerializer
(HashSet<String> ignoredEntries, JavaType keyType, JavaType valueType, boolean valueTypeIsStatic, TypeSerializer vts, JsonSerializer<Object> keySerializer, JsonSerializer<Object> valueSerializer, BeanProperty property) Deprecated. -
Uses of JsonSerializer in org.codehaus.jackson.map.ser.impl
Subclasses of JsonSerializer in org.codehaus.jackson.map.ser.implModifier and TypeClassDescriptionfinal class
Special bogus "serializer" that will throwJsonGenerationException
if itsFailingSerializer.serialize(java.lang.Object, org.codehaus.jackson.JsonGenerator, org.codehaus.jackson.map.SerializerProvider)
gets invoked.class
class
Fields in org.codehaus.jackson.map.ser.impl declared as JsonSerializerModifier and TypeFieldDescriptionfinal JsonSerializer<Object>
PropertySerializerMap.SerializerAndMapResult.serializer
Methods in org.codehaus.jackson.map.ser.impl that return JsonSerializerModifier and TypeMethodDescriptionprotected JsonSerializer<Object>
UnwrappingBeanPropertyWriter._findAndAddDynamic
(PropertySerializerMap map, Class<?> type, SerializerProvider provider) JsonSerializerMap.find
(SerializerCache.TypeKey key) abstract JsonSerializer<Object>
PropertySerializerMap.serializerFor
(Class<?> type) Main lookup method.ReadOnlyClassToSerializerMap.typedValueSerializer
(Class<?> cls) ReadOnlyClassToSerializerMap.typedValueSerializer
(JavaType type) SerializerCache.typedValueSerializer
(Class<?> cls) SerializerCache.typedValueSerializer
(JavaType type) ReadOnlyClassToSerializerMap.untypedValueSerializer
(Class<?> cls) ReadOnlyClassToSerializerMap.untypedValueSerializer
(JavaType type) SerializerCache.untypedValueSerializer
(Class<?> type) Method that checks if the shared (and hence, synchronized) lookup Map might have untyped serializer for given type.SerializerCache.untypedValueSerializer
(JavaType type) UnwrappingBeanSerializer.unwrappingSerializer()
Methods in org.codehaus.jackson.map.ser.impl with parameters of type JsonSerializerModifier and TypeMethodDescriptionvoid
SerializerCache.addAndResolveNonTypedSerializer
(Class<?> type, JsonSerializer<Object> ser, SerializerProvider provider) void
SerializerCache.addAndResolveNonTypedSerializer
(JavaType type, JsonSerializer<Object> ser, SerializerProvider provider) void
SerializerCache.addTypedSerializer
(Class<?> cls, JsonSerializer<Object> ser) void
SerializerCache.addTypedSerializer
(JavaType type, JsonSerializer<Object> ser) Method called if none of lookups succeeded, and caller had to construct a serializer.abstract PropertySerializerMap
PropertySerializerMap.newWith
(Class<?> type, JsonSerializer<Object> serializer) UnwrappingBeanPropertyWriter.withSerializer
(JsonSerializer<Object> ser) Method parameters in org.codehaus.jackson.map.ser.impl with type arguments of type JsonSerializerModifier and TypeMethodDescriptionstatic ReadOnlyClassToSerializerMap
ReadOnlyClassToSerializerMap.from
(HashMap<SerializerCache.TypeKey, JsonSerializer<Object>> src) Factory method for creating the "blueprint" lookup map.Constructors in org.codehaus.jackson.map.ser.impl with parameters of type JsonSerializerModifierConstructorDescriptionSerializerAndMapResult
(JsonSerializer<Object> serializer, PropertySerializerMap map) Constructor parameters in org.codehaus.jackson.map.ser.impl with type arguments of type JsonSerializerModifierConstructorDescriptionJsonSerializerMap
(Map<SerializerCache.TypeKey, JsonSerializer<Object>> serializers) -
Uses of JsonSerializer in org.codehaus.jackson.map.ser.std
Subclasses of JsonSerializer in org.codehaus.jackson.map.ser.stdModifier and TypeClassDescriptionclass
Base class for serializers that will output contents as JSON arrays; typically serializers used forCollection
and array types.class
Base class both for the standard bean serializer, and couple of variants that only differ in small details.class
Standard serializer forCalendar
.class
Fallback serializer for cases where Collection is not known to be of type for which more specializer serializer exists (such as index-accessible List).class
Intermediate base class for types that contain element(s) of other types.class
For efficiency, we will serialize Dates as longs, instead of potentially more readable Strings.class
Specialized serializer forEnumMap
s.class
Standard serializer used forEnum
types.class
final class
Efficient implementation for serializingList
s that contains Strings and are random-accessible.class
Simple serializer forInetAddress
.class
class
Serializer class that can serialize Object that have aJsonValue
annotation to indicate that serialization should be done by calling the method annotated, and serializing result it returns.class
Standard serializer implementation for serializing {link java.util.Map} types.class
Intermediate base class for limited number of scalar types that should never include type information.class
This is a simple dummy serializer that will just output literal JSON null value whenever serialization is requested.class
Generic serializer for Object arrays (Object[]
).class
This is a simple dummy serializer that will just output raw values by calling toString() on value to serialize.class
class
Generic handler for types that implementJsonSerializable
.class
Generic handler for types that implementJsonSerializableWithType
.class
Base class used by all standard serializers.class
StaticListSerializerBase<T extends Collection<?>>
Intermediate base class for Lists, Collections and Arrays that contain static (non-dynamic) value types.static class
Base class for serializers that will output contents as JSON arrays.static final class
static final class
Unlike other integral number array serializers, we do not just print out byte values as numbers.static final class
Character arrays are different from other integral number arrays in that they are most likely to be textual data, and should be written as Strings, not arrays of entries.static final class
static final class
static final class
static final class
static final class
static final class
Standard serializer used forString[]
values.static class
This is an optimized serializer for Lists that can be efficiently traversed by index (as opposed to others, such asLinkedList
that can not}.static class
static final class
static final class
static final class
static final class
static final class
Also: default bean access will not do much good with Class.class.static final class
For now, File objects get serialized by just outputting absolute (but not canonical) name as String valueclass
Specialized serializer that can be used as the generic key serializer, when serializingMap
s to JSON Objects.static class
static class
static class
class
Efficient implement for serializingCollection
s that contain Strings.final class
This is the special serializer for regularString
s.class
class
We also want to directly support serialization ofTokenBuffer
; and since it is part of core package, it can not implementJsonSerializable
(which is only included in the mapper package)class
Simple general purpose serializer, useful for any type for whichObject.toString()
returns the desired JSON value.Fields in org.codehaus.jackson.map.ser.std declared as JsonSerializerModifier and TypeFieldDescriptionprotected JsonSerializer<Object>
AsArraySerializerBase._elementSerializer
Value serializer to use, if it can be statically determinedprotected JsonSerializer<Object>
ObjectArraySerializer._elementSerializer
Value serializer to use, if it can be statically determined.protected JsonSerializer<Object>
StdArraySerializers.StringArraySerializer._elementSerializer
Value serializer to use, if it's not the standard one (if it is we can optimize serialization a lot)protected JsonSerializer<Object>
MapSerializer._keySerializer
Key serializer to use, if it can be statically determinedprotected JsonSerializer<String>
IndexedStringListSerializer._serializer
protected JsonSerializer<String>
StringCollectionSerializer._serializer
protected JsonSerializer<Object>
EnumMapSerializer._valueSerializer
Value serializer to use, if it can be statically determinedprotected JsonSerializer<Object>
JsonValueSerializer._valueSerializer
protected JsonSerializer<Object>
MapSerializer._valueSerializer
Value serializer to use, if it can be statically determinedprotected static final JsonSerializer<Object>
StdKeySerializers.DEFAULT_KEY_SERIALIZER
protected static final JsonSerializer<Object>
StdKeySerializers.DEFAULT_STRING_SERIALIZER
protected static final JsonSerializer<?>
StdKeySerializers.CalendarKeySerializer.instance
protected static final JsonSerializer<?>
StdKeySerializers.DateKeySerializer.instance
Methods in org.codehaus.jackson.map.ser.std that return JsonSerializerModifier and TypeMethodDescriptionprotected final JsonSerializer<Object>
AsArraySerializerBase._findAndAddDynamic
(PropertySerializerMap map, Class<?> type, SerializerProvider provider) protected final JsonSerializer<Object>
AsArraySerializerBase._findAndAddDynamic
(PropertySerializerMap map, JavaType type, SerializerProvider provider) protected final JsonSerializer<Object>
MapSerializer._findAndAddDynamic
(PropertySerializerMap map, Class<?> type, SerializerProvider provider) protected final JsonSerializer<Object>
MapSerializer._findAndAddDynamic
(PropertySerializerMap map, JavaType type, SerializerProvider provider) protected final JsonSerializer<Object>
ObjectArraySerializer._findAndAddDynamic
(PropertySerializerMap map, Class<?> type, SerializerProvider provider) protected final JsonSerializer<Object>
ObjectArraySerializer._findAndAddDynamic
(PropertySerializerMap map, JavaType type, SerializerProvider provider) static JsonSerializer<?>
StdContainerSerializers.enumSetSerializer
(JavaType enumType, BeanProperty property) static JsonSerializer<Object>
StdKeySerializers.getStdKeySerializer
(JavaType keyType) Methods in org.codehaus.jackson.map.ser.std with parameters of type JsonSerializerModifier and TypeMethodDescriptionstatic ContainerSerializerBase<?>
StdContainerSerializers.collectionSerializer
(JavaType elemType, boolean staticTyping, TypeSerializer vts, BeanProperty property, JsonSerializer<Object> valueSerializer) static MapSerializer
MapSerializer.construct
(String[] ignoredList, JavaType mapType, boolean staticValueType, TypeSerializer vts, BeanProperty property, JsonSerializer<Object> keySerializer, JsonSerializer<Object> valueSerializer) static ContainerSerializerBase<?>
StdContainerSerializers.indexedListSerializer
(JavaType elemType, boolean staticTyping, TypeSerializer vts, BeanProperty property, JsonSerializer<Object> valueSerializer) protected boolean
SerializerBase.isDefaultSerializer
(JsonSerializer<?> serializer) Method that can be called to determine if given serializer is the default serializer Jackson uses; as opposed to a custom serializer installed by a module or calling application.protected boolean
JsonValueSerializer.isNaturalTypeWithStdHandling
(JavaType type, JsonSerializer<?> ser) void
CollectionSerializer.serializeContentsUsing
(Collection<?> value, JsonGenerator jgen, SerializerProvider provider, JsonSerializer<Object> ser) protected void
EnumMapSerializer.serializeContentsUsing
(EnumMap<? extends Enum<?>, ?> value, JsonGenerator jgen, SerializerProvider provider, JsonSerializer<Object> valueSer) void
ObjectArraySerializer.serializeContentsUsing
(Object[] value, JsonGenerator jgen, SerializerProvider provider, JsonSerializer<Object> ser) void
StdContainerSerializers.IndexedListSerializer.serializeContentsUsing
(List<?> value, JsonGenerator jgen, SerializerProvider provider, JsonSerializer<Object> ser) protected void
MapSerializer.serializeFieldsUsing
(Map<?, ?> value, JsonGenerator jgen, SerializerProvider provider, JsonSerializer<Object> ser) Method called to serialize fields, when the value type is statically known, so that value serializer is passed and does not need to be fetched from provider.Constructors in org.codehaus.jackson.map.ser.std with parameters of type JsonSerializerModifierConstructorDescriptionprotected
AsArraySerializerBase
(Class<?> cls, JavaType et, boolean staticTyping, TypeSerializer vts, BeanProperty property, JsonSerializer<Object> elementSerializer) CollectionSerializer
(JavaType elemType, boolean staticTyping, TypeSerializer vts, BeanProperty property, JsonSerializer<Object> valueSerializer) EnumMapSerializer
(JavaType valueType, boolean staticTyping, EnumValues keyEnums, TypeSerializer vts, BeanProperty property, JsonSerializer<Object> valueSerializer) IndexedListSerializer
(JavaType elemType, boolean staticTyping, TypeSerializer vts, BeanProperty property, JsonSerializer<Object> valueSerializer) IndexedStringListSerializer
(BeanProperty property, JsonSerializer<?> ser) JsonValueSerializer
(Method valueMethod, JsonSerializer<Object> ser, BeanProperty property) protected
MapSerializer
(HashSet<String> ignoredEntries, JavaType keyType, JavaType valueType, boolean valueTypeIsStatic, TypeSerializer vts, JsonSerializer<Object> keySerializer, JsonSerializer<Object> valueSerializer, BeanProperty property) ObjectArraySerializer
(JavaType elemType, boolean staticTyping, TypeSerializer vts, BeanProperty property, JsonSerializer<Object> elementSerializer) StringCollectionSerializer
(BeanProperty property, JsonSerializer<?> ser) -
Uses of JsonSerializer in org.codehaus.jackson.xc
Subclasses of JsonSerializer in org.codehaus.jackson.xcModifier and TypeClassDescriptionclass
class
class
Fields in org.codehaus.jackson.xc declared as JsonSerializerModifier and TypeFieldDescriptionprotected final JsonSerializer<?>
JaxbAnnotationIntrospector._dataHandlerSerializer
Methods in org.codehaus.jackson.xc that return JsonSerializer