Uses of Class
com.fasterxml.jackson.databind.JavaType
-
Packages that use JavaType Package Description com.fasterxml.jackson.databind Basic data binding (mapping) functionality that allows for reading JSON content into Java Objects (POJOs) and JSON Trees (JsonNode
), as well as writing Java Objects and trees as JSON.com.fasterxml.jackson.databind.cfg Package that contains most of configuration-related classes; exception being couple of most-commonly used configuration things (like Feature enumerations) that are at the main level (com.fasterxml.jackson.databind
).com.fasterxml.jackson.databind.deser Contains implementation classes of deserialization part of data binding.com.fasterxml.jackson.databind.deser.impl Contains those implementation classes of deserialization part of data binding that are not considered part of public or semi-public interfaces.com.fasterxml.jackson.databind.deser.std Contains public standard implementations of abstraction that Jackson uses.com.fasterxml.jackson.databind.exc com.fasterxml.jackson.databind.ext 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.com.fasterxml.jackson.databind.introspect Functionality needed for Bean introspection, required for detecting accessors and mutators for Beans, as well as locating and handling method annotations.com.fasterxml.jackson.databind.jsonFormatVisitors Classes used for exposing logical structure of POJOs as Jackson sees it, and exposed viaObjectMapper.acceptJsonFormatVisitor(Class, JsonFormatVisitorWrapper)
andObjectMapper.acceptJsonFormatVisitor(com.fasterxml.jackson.databind.JavaType, JsonFormatVisitorWrapper)
methods.com.fasterxml.jackson.databind.jsontype Package that contains interfaces that define how to implement functionality for dynamically resolving type during deserialization.com.fasterxml.jackson.databind.jsontype.impl Package that contains standard implementations forTypeResolverBuilder
andTypeIdResolver
.com.fasterxml.jackson.databind.module Package that contains classes and interfaces to help implement custom extensionModule
s (which are registered usingObjectMapper.registerModule(com.fasterxml.jackson.databind.Module)
.com.fasterxml.jackson.databind.ser Contains implementation classes of serialization part of data binding.com.fasterxml.jackson.databind.ser.impl Contains implementation classes of serialization part of data binding.com.fasterxml.jackson.databind.ser.std com.fasterxml.jackson.databind.type Package that contains concrete implementations ofJavaType
, as well as the factory (TypeFactory
) for constructing instances from various input data types (likeClass
,Type
) and programmatically (for structured types, arrays,List
s andMap
s).com.fasterxml.jackson.databind.util Utility classes for Mapper package. -
-
Uses of JavaType in com.fasterxml.jackson.databind
Fields in com.fasterxml.jackson.databind declared as JavaType Modifier and Type Field Description protected JavaType
ObjectReader. _jsonNodeType
protected JavaType
BeanDescription. _type
Bean type information, including raw class and possible generics informationprotected JavaType
BeanProperty.Std. _type
protected JavaType
MappingIterator. _type
Type to bind individual elements to.protected JavaType
ObjectReader. _valueType
Declared type of value to instantiate during deserialization.Fields in com.fasterxml.jackson.databind with type parameters of type JavaType Modifier and Type Field Description protected LinkedNode<JavaType>
DeserializationContext. _currentType
Type ofJsonDeserializer
(or, more specifically,ContextualDeserializer
) that is being contextualized currently.protected java.util.concurrent.ConcurrentHashMap<JavaType,JsonDeserializer<java.lang.Object>>
ObjectMapper. _rootDeserializers
We will use a separate main-level Map for keeping track of root-level deserializers.protected java.util.concurrent.ConcurrentHashMap<JavaType,JsonDeserializer<java.lang.Object>>
ObjectReader. _rootDeserializers
Root-level cached deserializers.Methods in com.fasterxml.jackson.databind that return JavaType Modifier and Type Method Description protected JavaType
ObjectReader. _jsonNodeType()
protected abstract JavaType
JavaType. _narrow(java.lang.Class<?> subclass)
Deprecated.abstract JavaType
DatabindContext. constructSpecializedType(JavaType baseType, java.lang.Class<?> subclass)
Convenience method for constructing subtypes, retaining generic type parameter (if any).JavaType
DeserializationContext. constructSpecializedType(JavaType baseType, java.lang.Class<?> subclass)
JavaType
SerializerProvider. constructSpecializedType(JavaType baseType, java.lang.Class<?> subclass)
JavaType
DatabindContext. constructType(java.lang.reflect.Type type)
Convenience method for constructingJavaType
for given JDK type (usuallyClass
)JavaType
DeserializationContext. constructType(java.lang.Class<?> cls)
Convenience method, functionally equivalent to:JavaType
ObjectMapper. constructType(com.fasterxml.jackson.core.type.TypeReference<?> typeRef)
Convenience method for constructingJavaType
out of given type reference.JavaType
ObjectMapper. constructType(java.lang.reflect.Type t)
Convenience method for constructingJavaType
out of given type (typicallyjava.lang.Class
), but without explicit context.abstract JavaType
JavaType. containedType(int index)
JavaType
JavaType. containedTypeOrUnknown(int index)
Convenience method that is functionally same as:JavaType t = containedType(index); if (t == null) { t = TypeFactory.unknownType(); }
and typically used to eliminate need for null checks for common case where we just want to check if containedType is available first; and if not, use "unknown type" (which translates tojava.lang.Object
basically).abstract JavaType
JavaType. findSuperType(java.lang.Class<?> erasedTarget)
Method that may be called to find representation of given type within type hierarchy of this type: either this type (if this type has given erased type), one of its supertypes that has the erased types, or null if target is neither this type or any of its supertypes.JavaType
AbstractTypeResolver. findTypeMapping(DeserializationConfig config, JavaType type)
Try to locate a subtype for given abstract type, to either resolve to a concrete type, or at least to a more-specific (and hopefully supported) abstract type, one which may have registered deserializers.abstract JavaType[]
JavaType. findTypeParameters(java.lang.Class<?> expType)
Method that may be used to find paramaterization this type has for given type-erased generic target type.JavaType
JavaType. forcedNarrowBy(java.lang.Class<?> subclass)
Deprecated.JavaType
JavaType. getContentType()
JavaType
DeserializationContext. getContextualType()
Accessor toJavaType
of currently contextualizedContextualDeserializer
, if any.JavaType
JavaType. getKeyType()
JavaType
JavaType. getReferencedType()
abstract JavaType
JavaType. getSuperClass()
Accessor for finding fully resolved parent class of this type, if it has one; null if not.JavaType
BeanDescription. getType()
Method for accessing declared type of bean being introspected, including full generic type information (from declaration)JavaType
BeanProperty.Bogus. getType()
JavaType
BeanProperty. getType()
Method to get declared type of the property.JavaType
BeanProperty.Std. getType()
JavaType
ObjectReader. getValueType()
JavaType
DeserializationContext. handleMissingTypeId(JavaType baseType, TypeIdResolver idResolver, java.lang.String extraDesc)
JavaType
DeserializationContext. handleUnknownTypeId(JavaType baseType, java.lang.String id, TypeIdResolver idResolver, java.lang.String extraDesc)
Method that deserializers should call if they encounter a type id (for polymorphic deserialization) that cannot be resolved to an actual type; usually since there is no mapping defined.abstract JavaType
JavaType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
Mutant factory method that will try to create and return a sub-type instance for known parameterized types; for other types will return `null` to indicate that no just refinement makes necessary sense, without trying to detect special status through implemented interfaces.JavaType
AnnotationIntrospector. refineDeserializationType(MapperConfig<?> config, Annotated a, JavaType baseType)
Method called to find out possible type refinements to use for deserialization.JavaType
AnnotationIntrospector. refineSerializationType(MapperConfig<?> config, Annotated a, JavaType baseType)
Method called to find out possible type refinements to use for deserialization, including not just value itself but key and/or content type, if type has those.JavaType
AbstractTypeResolver. resolveAbstractType(DeserializationConfig config, BeanDescription typeDesc)
Method called to try to resolve an abstract type into concrete type (usually for purposes of deserializing), when no concrete implementation was found.JavaType
AbstractTypeResolver. resolveAbstractType(DeserializationConfig config, JavaType type)
Deprecated.since 2.8 (may be removed from 2.9 or later)JavaType
DatabindContext. resolveAndValidateSubType(JavaType baseType, java.lang.String subClass, PolymorphicTypeValidator ptv)
Lookup method similar toDatabindContext.resolveSubType(com.fasterxml.jackson.databind.JavaType, java.lang.String)
but one that also validates that resulting subtype is valid according to givenPolymorphicTypeValidator
.JavaType
DatabindContext. resolveSubType(JavaType baseType, java.lang.String subClassName)
Lookup method called when code needs to resolve class name from input; usually simple lookup.abstract JavaType
BeanDescription. resolveType(java.lang.reflect.Type jdkType)
Deprecated.Since 2.8, should simply callgetType
of property accessor directly.abstract JavaType
JavaType. withContentType(JavaType contentType)
Mutant factory method that may be called on structured types that have a so-called content type (element of arrays, value type of Maps, referenced type of referential types), and will construct a new instance that is identical to this instance, except that it has specified content type, instead of current one.abstract JavaType
JavaType. withContentTypeHandler(java.lang.Object h)
Mutant factory method that will construct a new instance that is identical to this instance, except that it will have specified content type (element type for arrays, value type for Maps and so forth) handler assigned.abstract JavaType
JavaType. withContentValueHandler(java.lang.Object h)
Mutant factory method that will construct a new instance that is identical to this instance, except that it will have specified content value handler assigned.JavaType
JavaType. withHandlersFrom(JavaType src)
Mutant factory method that will try to copy handlers that the specified source type instance had, if any; this must be done recursively where necessary (as content types may be structured).abstract JavaType
JavaType. withStaticTyping()
Method that can be called to get a type instance that indicates that values of the type should be handled using "static typing" for purposes of serialization (as opposed to "dynamic" aka runtime typing): meaning that no runtime information is needed for determining serializers to use.abstract JavaType
JavaType. withTypeHandler(java.lang.Object h)
"Copy method" that will construct a new instance that is identical to this instance, except that it will have specified type handler assigned.abstract JavaType
JavaType. withValueHandler(java.lang.Object h)
Mutant factory method that will construct a new instance that is identical to this instance, except that it will have specified value handler assigned.Methods in com.fasterxml.jackson.databind that return types with arguments of type JavaType Modifier and Type Method Description abstract java.util.List<JavaType>
JavaType. getInterfaces()
Accessor for finding fully resolved interfaces this type implements, if any; empty array if none.Methods in com.fasterxml.jackson.databind with parameters of type JavaType Modifier and Type Method Description protected java.lang.Object
ObjectMapper. _convert(java.lang.Object fromValue, JavaType toValueType)
Actual conversion implementation: instead of using existing read and write methods, much of code is inlined.protected JsonSerializer<java.lang.Object>
SerializerProvider. _createAndCacheUntypedSerializer(JavaType type)
protected JsonSerializer<java.lang.Object>
SerializerProvider. _createUntypedSerializer(JavaType type)
protected JsonDeserializer<java.lang.Object>
ObjectMapper. _findRootDeserializer(DeserializationContext ctxt, JavaType valueType)
Method called to locate deserializer for the passed root-level value.protected com.fasterxml.jackson.core.JsonToken
ObjectMapper. _initForReading(com.fasterxml.jackson.core.JsonParser p, JavaType targetType)
Method called to ensure that given parser is ready for reading content for data binding.protected ObjectReader
ObjectReader. _new(ObjectReader base, DeserializationConfig config, JavaType valueType, JsonDeserializer<java.lang.Object> rootDeser, java.lang.Object valueToUpdate, com.fasterxml.jackson.core.FormatSchema schema, InjectableValues injectableValues, DataFormatReaders dataFormatReaders)
Overridable factory method called by various "withXxx()" methodsprotected ObjectReader
ObjectMapper. _newReader(DeserializationConfig config, JavaType valueType, java.lang.Object valueToUpdate, com.fasterxml.jackson.core.FormatSchema schema, InjectableValues injectableValues)
Factory method sub-classes must override, to produceObjectReader
instances of proper sub-typeprotected ObjectWriter
ObjectMapper. _newWriter(SerializationConfig config, JavaType rootType, com.fasterxml.jackson.core.PrettyPrinter pp)
Factory method sub-classes must override, to produceObjectWriter
instances of proper sub-typeprotected JsonDeserializer<java.lang.Object>
ObjectReader. _prefetchRootDeserializer(JavaType valueType)
Method called to locate deserializer ahead of time, if permitted by configuration.protected java.lang.Object
ObjectMapper. _readMapAndClose(com.fasterxml.jackson.core.JsonParser p0, JavaType valueType)
protected java.lang.Object
ObjectMapper. _readValue(DeserializationConfig cfg, com.fasterxml.jackson.core.JsonParser p, JavaType valueType)
Actual implementation of value reading+binding operation.protected void
SerializerProvider. _reportIncompatibleRootType(java.lang.Object value, JavaType rootType)
protected <T> T
DatabindContext. _throwNotASubtype(JavaType baseType, java.lang.String subType)
protected <T> T
DatabindContext. _throwSubtypeClassNotAllowed(JavaType baseType, java.lang.String subType, PolymorphicTypeValidator ptv)
protected <T> T
DatabindContext. _throwSubtypeNameNotAllowed(JavaType baseType, java.lang.String subType, PolymorphicTypeValidator ptv)
protected void
ObjectMapper. _verifyNoTrailingTokens(com.fasterxml.jackson.core.JsonParser p, DeserializationContext ctxt, JavaType bindType)
protected void
ObjectReader. _verifyNoTrailingTokens(com.fasterxml.jackson.core.JsonParser p, DeserializationContext ctxt, JavaType bindType)
protected SequenceWriter
SequenceWriter. _writeCloseableValue(java.lang.Object value, JavaType type)
void
JsonSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType type)
Default implementation simply callsJsonFormatVisitorWrapper.expectAnyFormat(JavaType)
.void
ObjectMapper. acceptJsonFormatVisitor(JavaType type, JsonFormatVisitorWrapper visitor)
Method for visiting type hierarchy for given type, using specified visitor.void
ObjectWriter. acceptJsonFormatVisitor(JavaType type, JsonFormatVisitorWrapper visitor)
Method for visiting type hierarchy for given type, using specified visitor.TypeDeserializer
ObjectMapper.DefaultTypeResolverBuilder. buildTypeDeserializer(DeserializationConfig config, JavaType baseType, java.util.Collection<NamedType> subtypes)
TypeSerializer
ObjectMapper.DefaultTypeResolverBuilder. buildTypeSerializer(SerializationConfig config, JavaType baseType, java.util.Collection<NamedType> subtypes)
boolean
ObjectMapper. canDeserialize(JavaType type)
Method that can be called to check whether mapper thinks it could deserialize an Object of given type.boolean
ObjectMapper. canDeserialize(JavaType type, java.util.concurrent.atomic.AtomicReference<java.lang.Throwable> cause)
Method similar toObjectMapper.canDeserialize(JavaType)
but that can return actualThrowable
that was thrown when trying to construct serializer: this may be useful in figuring out what the actual problem is.abstract JavaType
DatabindContext. constructSpecializedType(JavaType baseType, java.lang.Class<?> subclass)
Convenience method for constructing subtypes, retaining generic type parameter (if any).JavaType
DeserializationContext. constructSpecializedType(JavaType baseType, java.lang.Class<?> subclass)
JavaType
SerializerProvider. constructSpecializedType(JavaType baseType, java.lang.Class<?> subclass)
<T> T
ObjectMapper. convertValue(java.lang.Object fromValue, JavaType toValueType)
JsonSerializer<java.lang.Object>
SerializerProvider. findContentValueSerializer(JavaType valueType, BeanProperty property)
Alternative toSerializerProvider.findPrimaryPropertySerializer(JavaType, BeanProperty)
called not for primary value, but "content" of such primary serializer: element of an array orCollection
, value ofMap
entry and so on.JsonDeserializer<java.lang.Object>
DeserializationContext. findContextualValueDeserializer(JavaType type, BeanProperty prop)
Method for finding a value deserializer, and creating a contextual version if necessary, for value reached via specified property.java.lang.Class<?>
AnnotationIntrospector. findDeserializationContentType(Annotated ann, JavaType baseContentType)
java.lang.Class<?>
AnnotationIntrospector. findDeserializationKeyType(Annotated ann, JavaType baseKeyType)
java.lang.Class<?>
AnnotationIntrospector. findDeserializationType(Annotated ann, JavaType baseType)
KeyDeserializer
DeserializationContext. findKeyDeserializer(JavaType keyType, BeanProperty prop)
Convenience method, functionally same as:JsonSerializer<java.lang.Object>
SerializerProvider. findKeySerializer(JavaType keyType, BeanProperty property)
Method called to get the serializer to use for serializing non-null Map keys.JsonDeserializer<java.lang.Object>
DeserializationContext. findNonContextualValueDeserializer(JavaType type)
Variant that will try to locate deserializer for current type, but without performing any contextualization (unlikeDeserializationContext.findContextualValueDeserializer(com.fasterxml.jackson.databind.JavaType, com.fasterxml.jackson.databind.BeanProperty)
) or checking for need to create aTypeDeserializer
(unlikeDeserializationContext.findRootValueDeserializer(JavaType)
.JsonSerializer<java.lang.Object>
SerializerProvider. findNullKeySerializer(JavaType serializationType, BeanProperty property)
Method called to find a serializer to use for null values for given declared type.JsonSerializer<java.lang.Object>
SerializerProvider. findPrimaryPropertySerializer(JavaType valueType, BeanProperty property)
Similar toSerializerProvider.findValueSerializer(JavaType, BeanProperty)
, but used when finding "primary" property value serializer (one directly handling value of the property).TypeResolverBuilder<?>
AnnotationIntrospector. findPropertyContentTypeResolver(MapperConfig<?> config, AnnotatedMember am, JavaType containerType)
Method for checking if given structured property entity (field or method that has nominal value of Map, Collection or array type) has annotations that indicate that specific type resolver is to be used for handling type information of contained values.TypeResolverBuilder<?>
AnnotationIntrospector. findPropertyTypeResolver(MapperConfig<?> config, AnnotatedMember am, JavaType baseType)
Method for checking if given property entity (field or method) has annotations that indicate that specific type resolver is to be used for handling instances.JsonDeserializer<java.lang.Object>
DeserializationContext. findRootValueDeserializer(JavaType type)
Method for finding a deserializer for root-level value.java.lang.Class<?>
AnnotationIntrospector. findSerializationContentType(Annotated am, JavaType baseType)
java.lang.Class<?>
AnnotationIntrospector. findSerializationKeyType(Annotated am, JavaType baseType)
TypeDeserializer
DeserializationConfig. findTypeDeserializer(JavaType baseType)
Helper method that is needed to properly handle polymorphic referenced types, such as types referenced byAtomicReference
, or various "optional" types.JsonSerializer<java.lang.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.JavaType
AbstractTypeResolver. findTypeMapping(DeserializationConfig config, JavaType type)
Try to locate a subtype for given abstract type, to either resolve to a concrete type, or at least to a more-specific (and hopefully supported) abstract type, one which may have registered deserializers.TypeResolverBuilder<?>
AnnotationIntrospector. findTypeResolver(MapperConfig<?> config, AnnotatedClass ac, JavaType baseType)
Method for checking if given class has annotations that indicate that specific type resolver is to be used for handling instances.TypeSerializer
SerializerProvider. findTypeSerializer(JavaType javaType)
Method called to get theTypeSerializer
to use for including Type Id necessary for serializing for the given Java class.JsonSerializer<java.lang.Object>
SerializerProvider. findValueSerializer(JavaType valueType)
Method variant used when we do NOT want contextualization to happen; it will need to be handled at a later point, but caller wants to be able to do that as needed; sometimes to avoid infinite loopsJsonSerializer<java.lang.Object>
SerializerProvider. findValueSerializer(JavaType valueType, BeanProperty property)
Similar toSerializerProvider.findValueSerializer(Class,BeanProperty)
, but takes full generics-aware type instead of raw class.ObjectWriter.Prefetch
ObjectWriter.Prefetch. forRootType(ObjectWriter parent, JavaType newType)
ObjectReader
ObjectReader. forType(JavaType valueType)
Method for constructing a new reader instance that is configured to data bind into specified type.ObjectWriter
ObjectWriter. forType(JavaType rootType)
Method that will construct a new instance that uses specific type as the root type for serialization, instead of runtime dynamic type of the root object itself.JavaType
DeserializationContext. handleMissingTypeId(JavaType baseType, TypeIdResolver idResolver, java.lang.String extraDesc)
JsonDeserializer<?>
DeserializationContext. handlePrimaryContextualization(JsonDeserializer<?> deser, BeanProperty prop, JavaType type)
Method called for primary property deserializers (ones directly created to deserialize values of a POJO property), to handle details of resolvingContextualDeserializer
with given property context.JsonDeserializer<?>
DeserializationContext. handleSecondaryContextualization(JsonDeserializer<?> deser, BeanProperty prop, JavaType type)
Method called for secondary property deserializers (ones NOT directly created to deal with an annotatable POJO property, but instead created as a component -- such as value deserializers for structured types, or deserializers for root values) to handle details of resolvingContextualDeserializer
with given property context.java.lang.Object
DeserializationContext. handleUnexpectedToken(JavaType targetType, com.fasterxml.jackson.core.JsonParser p)
Method that deserializers should call if the first token of the value to deserialize is of unexpected type (that is, type of token that deserializer cannot handle).java.lang.Object
DeserializationContext. handleUnexpectedToken(JavaType targetType, com.fasterxml.jackson.core.JsonToken t, com.fasterxml.jackson.core.JsonParser p, java.lang.String msg, java.lang.Object... msgArgs)
Method that deserializers should call if the first token of the value to deserialize is of unexpected type (that is, type of token that deserializer cannot handle).JavaType
DeserializationContext. handleUnknownTypeId(JavaType baseType, java.lang.String id, TypeIdResolver idResolver, java.lang.String extraDesc)
Method that deserializers should call if they encounter a type id (for polymorphic deserialization) that cannot be resolved to an actual type; usually since there is no mapping defined.java.lang.Object
DeserializationContext. handleWeirdNativeValue(JavaType targetType, java.lang.Object badValue, com.fasterxml.jackson.core.JsonParser p)
boolean
DeserializationContext. hasValueDeserializerFor(JavaType type, java.util.concurrent.atomic.AtomicReference<java.lang.Throwable> cause)
Method for checking whether we could find a deserializer for given type.BeanDescription
DeserializationConfig. introspect(JavaType type)
Method that will introspect full bean properties for the purpose of building a bean deserializerBeanDescription
SerializationConfig. introspect(JavaType type)
Method that will introspect full bean properties for the purpose of building a bean serializerBeanDescription
DeserializationConfig. introspectForBuilder(JavaType type)
Deprecated.Since 2.12 - use variant that takes both builder and value typeBeanDescription
DeserializationConfig. introspectForBuilder(JavaType builderType, BeanDescription valueTypeDesc)
BeanDescription
DeserializationConfig. introspectForCreation(JavaType type)
Method that will introspect subset of bean properties needed to construct bean instance.protected abstract JsonMappingException
DatabindContext. invalidTypeIdException(JavaType baseType, java.lang.String typeId, java.lang.String extraDesc)
Helper method for constructing exception to indicate that given type id could not be resolved to a valid subtype of specified base type.JsonMappingException
DeserializationContext. invalidTypeIdException(JavaType baseType, java.lang.String typeId, java.lang.String extraDesc)
JsonMappingException
SerializerProvider. invalidTypeIdException(JavaType baseType, java.lang.String typeId, java.lang.String extraDesc)
JsonMappingException
DeserializationContext. missingTypeIdException(JavaType baseType, java.lang.String extraDesc)
ObjectReader
ObjectMapper. reader(JavaType type)
Deprecated.Since 2.5, useObjectMapper.readerFor(JavaType)
insteadObjectReader
ObjectMapper. readerFor(JavaType type)
Factory method for constructingObjectReader
that will read or update instances of specified type<T> T
DeserializationContext. readPropertyValue(com.fasterxml.jackson.core.JsonParser p, BeanProperty prop, JavaType type)
<T> T
DeserializationContext. readValue(com.fasterxml.jackson.core.JsonParser p, JavaType type)
<T> T
ObjectMapper. readValue(byte[] src, int offset, int len, JavaType valueType)
<T> T
ObjectMapper. readValue(byte[] src, JavaType valueType)
<T> T
ObjectMapper. readValue(com.fasterxml.jackson.core.JsonParser p, JavaType valueType)
Type-safe overloaded method, basically alias forObjectMapper.readValue(JsonParser, Class)
.<T> T
ObjectMapper. readValue(java.io.DataInput src, JavaType valueType)
<T> T
ObjectMapper. readValue(java.io.File src, JavaType valueType)
Method to deserialize JSON content from given file into given Java type.<T> T
ObjectMapper. readValue(java.io.InputStream src, JavaType valueType)
<T> T
ObjectMapper. readValue(java.io.Reader src, JavaType valueType)
<T> T
ObjectMapper. readValue(java.lang.String content, JavaType valueType)
Method to deserialize JSON content from given JSON content String.<T> T
ObjectMapper. readValue(java.net.URL src, JavaType valueType)
Same asObjectMapper.readValue(java.net.URL, Class)
except that target specified byJavaType
.<T> T
ObjectReader. readValue(com.fasterxml.jackson.core.JsonParser p, JavaType valueType)
Type-safe overloaded method, basically alias forObjectReader.readValue(JsonParser, ResolvedType)
.<T> MappingIterator<T>
ObjectMapper. readValues(com.fasterxml.jackson.core.JsonParser p, JavaType valueType)
Convenience method, equivalent in function to:<T> java.util.Iterator<T>
ObjectReader. readValues(com.fasterxml.jackson.core.JsonParser p, JavaType valueType)
Convenience method that is equivalent to:abstract JavaType
JavaType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
Mutant factory method that will try to create and return a sub-type instance for known parameterized types; for other types will return `null` to indicate that no just refinement makes necessary sense, without trying to detect special status through implemented interfaces.JavaType
AnnotationIntrospector. refineDeserializationType(MapperConfig<?> config, Annotated a, JavaType baseType)
Method called to find out possible type refinements to use for deserialization.JavaType
AnnotationIntrospector. refineSerializationType(MapperConfig<?> config, Annotated a, JavaType baseType)
Method called to find out possible type refinements to use for deserialization, including not just value itself but key and/or content type, if type has those.abstract <T> T
DatabindContext. reportBadDefinition(JavaType type, java.lang.String msg)
Helper method called to indicate a generic problem that stems from type definition(s), not input data, or input/output state; typically this means throwing aInvalidDefinitionException
.<T> T
DeserializationContext. reportBadDefinition(JavaType type, java.lang.String msg)
<T> T
SerializerProvider. reportBadDefinition(JavaType type, java.lang.String msg)
<T> T
SerializerProvider. reportBadDefinition(JavaType type, java.lang.String msg, java.lang.Throwable cause)
<T> T
DeserializationContext. reportInputMismatch(JavaType targetType, java.lang.String msg, java.lang.Object... msgArgs)
Helper method used to indicate a problem with input in cases where more specificreportXxx()
method was not available.<T> T
DeserializationContext. reportPropertyInputMismatch(JavaType targetType, java.lang.String propertyName, java.lang.String msg, java.lang.Object... msgArgs)
Helper method used to indicate a problem with input in cases where more specificreportXxx()
method was not available.void
DeserializationContext. reportWrongTokenException(JavaType targetType, com.fasterxml.jackson.core.JsonToken expToken, java.lang.String msg, java.lang.Object... msgArgs)
Method for deserializers to call when the token encountered was of type different than what should be seen at that position, usually within a sequence of expected tokens.JavaType
AbstractTypeResolver. resolveAbstractType(DeserializationConfig config, JavaType type)
Deprecated.since 2.8 (may be removed from 2.9 or later)JavaType
DatabindContext. resolveAndValidateSubType(JavaType baseType, java.lang.String subClass, PolymorphicTypeValidator ptv)
Lookup method similar toDatabindContext.resolveSubType(com.fasterxml.jackson.databind.JavaType, java.lang.String)
but one that also validates that resulting subtype is valid according to givenPolymorphicTypeValidator
.JavaType
DatabindContext. resolveSubType(JavaType baseType, java.lang.String subClassName)
Lookup method called when code needs to resolve class name from input; usually simple lookup.JsonMappingException
DeserializationContext. unknownTypeException(JavaType type, java.lang.String id, java.lang.String extraDesc)
boolean
ObjectMapper.DefaultTypeResolverBuilder. useForType(JavaType t)
Method called to check if the default type handler should be used for given type.abstract JavaType
JavaType. withContentType(JavaType contentType)
Mutant factory method that may be called on structured types that have a so-called content type (element of arrays, value type of Maps, referenced type of referential types), and will construct a new instance that is identical to this instance, except that it has specified content type, instead of current one.JavaType
JavaType. withHandlersFrom(JavaType src)
Mutant factory method that will try to copy handlers that the specified source type instance had, if any; this must be done recursively where necessary (as content types may be structured).BeanProperty.Std
BeanProperty.Std. withType(JavaType type)
ObjectReader
ObjectReader. withType(JavaType valueType)
Deprecated.since 2.5 UseObjectReader.forType(JavaType)
insteadObjectWriter
ObjectWriter. withType(JavaType rootType)
Deprecated.since 2.5 UseObjectWriter.forType(JavaType)
insteadSequenceWriter
SequenceWriter. write(java.lang.Object value, JavaType type)
Method for writing given value into output, as part of sequence to write; further, full type (often generic, likeMap
is passed in case a newJsonSerializer
needs to be fetched to handle type If root type was specified forObjectWriter
, value must be of compatible type (same or subtype).ObjectWriter
ObjectMapper. writerFor(JavaType rootType)
Factory method for constructingObjectWriter
that will serialize objects using specified root type, instead of actual runtime type of value.ObjectWriter
ObjectMapper. writerWithType(JavaType rootType)
Deprecated.Since 2.5, useObjectMapper.writerFor(JavaType)
insteadJsonMappingException
DeserializationContext. wrongTokenException(com.fasterxml.jackson.core.JsonParser p, JavaType targetType, com.fasterxml.jackson.core.JsonToken expToken, java.lang.String extra)
Helper method for constructingJsonMappingException
to indicate that the token encountered was of type different than what should be seen at that position, usually within a sequence of expected tokens.Constructors in com.fasterxml.jackson.databind with parameters of type JavaType Constructor Description BeanDescription(JavaType type)
JavaType(JavaType base)
Copy-constructor used when refining/upgrading type instances.MappingIterator(JavaType type, com.fasterxml.jackson.core.JsonParser p, DeserializationContext ctxt, JsonDeserializer<?> deser, boolean managedParser, java.lang.Object valueToUpdate)
ObjectReader(ObjectMapper mapper, DeserializationConfig config, JavaType valueType, java.lang.Object valueToUpdate, com.fasterxml.jackson.core.FormatSchema schema, InjectableValues injectableValues)
Constructor called when a root deserializer should be fetched based on other configuration.ObjectReader(ObjectReader base, DeserializationConfig config, JavaType valueType, JsonDeserializer<java.lang.Object> rootDeser, java.lang.Object valueToUpdate, com.fasterxml.jackson.core.FormatSchema schema, InjectableValues injectableValues, DataFormatReaders dataFormatReaders)
Copy constructor used for building variations.ObjectWriter(ObjectMapper mapper, SerializationConfig config, JavaType rootType, com.fasterxml.jackson.core.PrettyPrinter pp)
Constructor used byObjectMapper
for initial instantiationStd(BeanProperty.Std base, JavaType newType)
Std(PropertyName name, JavaType type, PropertyName wrapperName, AnnotatedMember member, PropertyMetadata metadata)
Std(PropertyName name, JavaType type, PropertyName wrapperName, Annotations contextAnnotations, AnnotatedMember member, PropertyMetadata metadata)
Deprecated.Since 2.9 -
Uses of JavaType in com.fasterxml.jackson.databind.cfg
Methods in com.fasterxml.jackson.databind.cfg that return JavaType Modifier and Type Method Description JavaType
MapperConfig. constructSpecializedType(JavaType baseType, java.lang.Class<?> subclass)
JavaType
MapperConfig. constructType(com.fasterxml.jackson.core.type.TypeReference<?> valueTypeRef)
Helper method that will constructJavaType
for given type reference This is a simple short-cut for:JavaType
MapperConfig. constructType(java.lang.Class<?> cls)
Helper method that will constructJavaType
for given raw class.Methods in com.fasterxml.jackson.databind.cfg with parameters of type JavaType Modifier and Type Method Description JavaType
MapperConfig. constructSpecializedType(JavaType baseType, java.lang.Class<?> subclass)
abstract PropertyName
MapperConfig. findRootName(JavaType rootType)
PropertyName
MapperConfigBase. findRootName(JavaType rootType)
TypeResolverBuilder<?>
MapperConfig. getDefaultTyper(JavaType baseType)
Method called to locate a type info handler for types that do not have one explicitly declared via annotations (or other configuration).BeanDescription
MapperConfig. introspectClassAnnotations(JavaType type)
Accessor for getting bean description that only contains class annotations: useful if no getter/setter/creator information is needed.BeanDescription
MapperConfig. introspectDirectClassAnnotations(JavaType type)
Accessor for getting bean description that only contains immediate class annotations: ones from the class, and its direct mix-in, if any, but not from super types. -
Uses of JavaType in com.fasterxml.jackson.databind.deser
Fields in com.fasterxml.jackson.databind.deser declared as JavaType Modifier and Type Field Description protected JavaType
AbstractDeserializer. _baseType
protected JavaType
BeanDeserializerBase. _beanType
Declared type of the bean this deserializer handles.protected JavaType
BuilderBasedDeserializer. _targetType
Type that the builder will produce, target type; as opposed to `handledType()` which refers to Builder class.protected JavaType
SettableAnyProperty. _type
protected JavaType
SettableBeanProperty. _type
Base type for property; may be a supertype of actual value.Fields in com.fasterxml.jackson.databind.deser with type parameters of type JavaType Modifier and Type Field Description protected LRUMap<JavaType,JsonDeserializer<java.lang.Object>>
DeserializerCache. _cachedDeserializers
We will also cache some dynamically constructed deserializers; specifically, ones that are expensive to construct.protected java.util.HashMap<JavaType,JsonDeserializer<java.lang.Object>>
DeserializerCache. _incompleteDeserializers
During deserializer construction process we may need to keep track of partially completed deserializers, to resolve cyclic dependencies.Methods in com.fasterxml.jackson.databind.deser that return JavaType Modifier and Type Method Description protected JavaType
BasicDeserializerFactory. _findRemappedType(DeserializationConfig config, java.lang.Class<?> rawType)
JavaType
ValueInstantiator.Delegating. getArrayDelegateType(DeserializationConfig config)
JavaType
ValueInstantiator. getArrayDelegateType(DeserializationConfig config)
Method that can be used to determine what is the type of array delegate type to use, if any; if no delegates are used, will return null.JavaType
ValueInstantiator.Delegating. getDelegateType(DeserializationConfig config)
JavaType
ValueInstantiator. getDelegateType(DeserializationConfig config)
Method that can be used to determine what is the type of delegate type to use, if any; if no delegates are used, will return null.JavaType
SettableAnyProperty. getType()
JavaType
SettableBeanProperty. getType()
JavaType
BeanDeserializerBase. getValueType()
JavaType
DeserializationProblemHandler. handleMissingTypeId(DeserializationContext ctxt, JavaType baseType, TypeIdResolver idResolver, java.lang.String failureMsg)
Handler method called if an expected type id for a polymorphic value is not found and no "default type" is specified or allowed.JavaType
DeserializationProblemHandler. handleUnknownTypeId(DeserializationContext ctxt, JavaType baseType, java.lang.String subTypeId, TypeIdResolver idResolver, java.lang.String failureMsg)
Handler method called if resolution of type id from given String failed to produce a subtype; usually because logical id is not mapped to actual implementation class.JavaType
BasicDeserializerFactory. mapAbstractType(DeserializationConfig config, JavaType type)
abstract JavaType
DeserializerFactory. mapAbstractType(DeserializationConfig config, JavaType type)
Method that can be called to try to resolve an abstract type (interface, abstract class) into a concrete type, or at least something "more concrete" (abstract class instead of interface).protected JavaType
BeanDeserializerFactory. materializeAbstractType(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
protected JavaType
BasicDeserializerFactory. modifyTypeByAnnotation(DeserializationContext ctxt, Annotated a, JavaType type)
protected JavaType
BasicDeserializerFactory. resolveMemberAndTypeAnnotations(DeserializationContext ctxt, AnnotatedMember member, JavaType type)
Helper method used to resolve additional type-related annotation information like type overrides, or handler (serializer, deserializer) overrides, so that from declared field, property or constructor parameter type is used as the base and modified based on annotations, if any.protected JavaType
BasicDeserializerFactory. resolveType(DeserializationContext ctxt, BeanDescription beanDesc, JavaType type, AnnotatedMember member)
Methods in com.fasterxml.jackson.databind.deser with parameters of type JavaType Modifier and Type Method Description protected JsonDeserializer<java.lang.Object>
DeserializerCache. _createAndCache2(DeserializationContext ctxt, DeserializerFactory factory, JavaType type)
Method that handles actual construction (via factory) and caching (both intermediate and eventual)protected JsonDeserializer<java.lang.Object>
DeserializerCache. _createAndCacheValueDeserializer(DeserializationContext ctxt, DeserializerFactory factory, JavaType type)
Method that will try to create a deserializer for given type, and resolve and cache it if necessaryprotected JsonDeserializer<java.lang.Object>
DeserializerCache. _createDeserializer(DeserializationContext ctxt, DeserializerFactory factory, JavaType type)
Method that does the heavy lifting of checking for per-type annotations, find out full type, and figure out which actual factory method to call.protected JsonDeserializer<?>
DeserializerCache. _createDeserializer2(DeserializationContext ctxt, DeserializerFactory factory, JavaType type, BeanDescription beanDesc)
protected JsonDeserializer<java.lang.Object>
DeserializerCache. _findCachedDeserializer(JavaType type)
protected JsonDeserializer<java.lang.Object>
BasicDeserializerFactory. _findCustomBeanDeserializer(JavaType type, DeserializationConfig config, BeanDescription beanDesc)
protected AnnotatedMethod
BasicDeserializerFactory. _findJsonValueFor(DeserializationConfig config, JavaType enumType)
Deprecated.since 2.8 callfindJsonValueMethod
onBeanDescription
insteadprotected JsonDeserializer<java.lang.Object>
BeanDeserializerFactory. _findUnsupportedTypeDeserializer(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
Helper method called to see if given type, otherwise to be taken as POJO type, is "known but not supported" JDK type, and if so, return alternate handler (deserializer).protected KeyDeserializer
DeserializerCache. _handleUnknownKeyDeserializer(DeserializationContext ctxt, JavaType type)
protected JsonDeserializer<java.lang.Object>
DeserializerCache. _handleUnknownValueDeserializer(DeserializationContext ctxt, JavaType type)
protected CollectionType
BasicDeserializerFactory. _mapAbstractCollectionType(JavaType type, DeserializationConfig config)
protected MapType
BasicDeserializerFactory. _mapAbstractMapType(JavaType type, DeserializationConfig config)
protected java.lang.Object
DefaultDeserializationContext. _unwrapAndDeserialize(com.fasterxml.jackson.core.JsonParser p, JavaType rootType, JsonDeserializer<java.lang.Object> deser, java.lang.Object valueToUpdate)
protected void
BeanDeserializerFactory. _validateSubType(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
void
BeanDeserializerBuilder. addInjectable(PropertyName propName, JavaType propType, Annotations contextAnnotations, AnnotatedMember member, java.lang.Object valueId)
JsonDeserializer<java.lang.Object>
BeanDeserializerFactory. buildBeanDeserializer(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
Method that is to actually build a bean deserializer instance.JsonDeserializer<?>
BeanDeserializerBuilder. buildBuilderBased(JavaType valueType, java.lang.String expBuildMethodName)
Method for constructing a specialized deserializer that uses additional external Builder object during data binding.protected JsonDeserializer<java.lang.Object>
BeanDeserializerFactory. buildBuilderBasedDeserializer(DeserializationContext ctxt, JavaType valueType, BeanDescription builderDesc)
Method for constructing a bean deserializer that uses specified intermediate Builder for binding data, and construction of the value instance.JsonDeserializer<java.lang.Object>
BeanDeserializerFactory. buildThrowableDeserializer(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
static CreatorProperty
CreatorProperty. construct(PropertyName name, JavaType type, PropertyName wrapperName, TypeDeserializer typeDeser, Annotations contextAnnotations, AnnotatedParameter param, int index, com.fasterxml.jackson.annotation.JacksonInject.Value injectable, PropertyMetadata metadata)
Factory method for creatingCreatorProperty
instancesprotected SettableBeanProperty
BeanDeserializerFactory. constructSettableProperty(DeserializationContext ctxt, BeanDescription beanDesc, BeanPropertyDefinition propDef, JavaType propType0)
Method that will construct a regular bean property setter using the given setter method.JsonDeserializer<java.lang.Object>
BeanDeserializerFactory. createBeanDeserializer(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
Method thatDeserializerCache
s call to create a new deserializer for types other than Collections, Maps, arrays and enums.abstract JsonDeserializer<java.lang.Object>
DeserializerFactory. createBeanDeserializer(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
Method called to create (or, for completely immutable deserializers, reuse) a deserializer that can convert JSON content into values of specified Java "bean" (POJO) type.protected JsonDeserializer<?>
BeanDeserializerBuilder. createBuilderBasedDeserializer(JavaType valueType, BeanPropertyMap propertyMap, boolean anyViews)
Extension point for overriding the actual creation of the builder deserializer.JsonDeserializer<java.lang.Object>
BeanDeserializerFactory. createBuilderBasedDeserializer(DeserializationContext ctxt, JavaType valueType, BeanDescription valueBeanDesc, java.lang.Class<?> builderClass)
abstract JsonDeserializer<java.lang.Object>
DeserializerFactory. createBuilderBasedDeserializer(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc, java.lang.Class<?> builderClass)
Method called to create a deserializer that will use specified Builder class for building value instances.JsonDeserializer<?>
BasicDeserializerFactory. createEnumDeserializer(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
Factory method for constructing serializers ofEnum
types.abstract JsonDeserializer<?>
DeserializerFactory. createEnumDeserializer(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
KeyDeserializer
BasicDeserializerFactory. createKeyDeserializer(DeserializationContext ctxt, JavaType type)
abstract KeyDeserializer
DeserializerFactory. createKeyDeserializer(DeserializationContext ctxt, JavaType type)
Method called to find if factory knows how to create a key deserializer for specified type; currently this means checking if a module has registered possible deserializers.JsonDeserializer<?>
BasicDeserializerFactory. createTreeDeserializer(DeserializationConfig config, JavaType nodeType, BeanDescription beanDesc)
abstract JsonDeserializer<?>
DeserializerFactory. createTreeDeserializer(DeserializationConfig config, JavaType type, BeanDescription beanDesc)
Method called to create and return a deserializer that can construct JsonNode(s) from JSON content.JsonDeserializer<?>
Deserializers.Base. findBeanDeserializer(JavaType type, DeserializationConfig config, BeanDescription beanDesc)
JsonDeserializer<?>
Deserializers. findBeanDeserializer(JavaType type, DeserializationConfig config, BeanDescription beanDesc)
Method called to locate deserializer for specified value type which does not belong to any other category (not an Enum, Collection, Map, Array, reference value or tree node)static java.lang.Class<?>
BasicDeserializerFactory.ContainerDefaultMappings. findCollectionFallback(JavaType type)
JsonDeserializer<?>
BasicDeserializerFactory. findDefaultDeserializer(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
Helper method called to find one of default serializers for "well-known" platform types: JDK-provided types, and small number of public Jackson API types.KeyDeserializer
DeserializerCache. findKeyDeserializer(DeserializationContext ctxt, DeserializerFactory factory, JavaType type)
Method called to get hold of a deserializer to use for deserializing keys forMap
.KeyDeserializer
KeyDeserializers. findKeyDeserializer(JavaType type, DeserializationConfig config, BeanDescription beanDesc)
static java.lang.Class<?>
BasicDeserializerFactory.ContainerDefaultMappings. findMapFallback(JavaType type)
protected JsonDeserializer<?>
BasicDeserializerFactory. findOptionalStdDeserializer(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
Overridable method called after checking all other types.TypeDeserializer
BasicDeserializerFactory. findPropertyContentTypeDeserializer(DeserializationConfig config, JavaType containerType, AnnotatedMember propertyEntity)
Method called to find and create a type information deserializer for values of given container (list, array, map) property, if one is needed.TypeDeserializer
BasicDeserializerFactory. findPropertyTypeDeserializer(DeserializationConfig config, JavaType baseType, AnnotatedMember annotated)
Method called to create a type information deserializer for values of given non-container property, if one is needed.protected JsonDeserializer<?>
BeanDeserializerFactory. findStdDeserializer(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
Method called byBeanDeserializerFactory
to see if there might be a standard deserializer registered for given type.TypeDeserializer
BasicDeserializerFactory. findTypeDeserializer(DeserializationConfig config, JavaType baseType)
abstract TypeDeserializer
DeserializerFactory. findTypeDeserializer(DeserializationConfig config, JavaType baseType)
Method called to find and create a type information deserializer for given base type, if one is needed.JsonDeserializer<java.lang.Object>
DeserializerCache. findValueDeserializer(DeserializationContext ctxt, DeserializerFactory factory, JavaType propertyType)
Method called to get hold of a deserializer for a value of given type; or if no such deserializer can be found, a default handler (which may do a best-effort generic serialization or just simply throw an exception when invoked).JavaType
DeserializationProblemHandler. handleMissingTypeId(DeserializationContext ctxt, JavaType baseType, TypeIdResolver idResolver, java.lang.String failureMsg)
Handler method called if an expected type id for a polymorphic value is not found and no "default type" is specified or allowed.java.lang.Object
DeserializationProblemHandler. handleUnexpectedToken(DeserializationContext ctxt, JavaType targetType, com.fasterxml.jackson.core.JsonToken t, com.fasterxml.jackson.core.JsonParser p, java.lang.String failureMsg)
Method that deserializers should call if the first token of the value to deserialize is of unexpected type (that is, type of token that deserializer cannot handle).JavaType
DeserializationProblemHandler. handleUnknownTypeId(DeserializationContext ctxt, JavaType baseType, java.lang.String subTypeId, TypeIdResolver idResolver, java.lang.String failureMsg)
Handler method called if resolution of type id from given String failed to produce a subtype; usually because logical id is not mapped to actual implementation class.java.lang.Object
DeserializationProblemHandler. handleWeirdNativeValue(DeserializationContext ctxt, JavaType targetType, java.lang.Object valueToConvert, com.fasterxml.jackson.core.JsonParser p)
Method called when an embedded (native) value (JsonToken.VALUE_EMBEDDED_OBJECT
) cannot be converted directly into expected value type (usually POJO).boolean
DeserializerCache. hasValueDeserializerFor(DeserializationContext ctxt, DeserializerFactory factory, JavaType type)
Method called to find out whether provider would be able to find a deserializer for given type, using a root reference (i.e.JavaType
BasicDeserializerFactory. mapAbstractType(DeserializationConfig config, JavaType type)
abstract JavaType
DeserializerFactory. mapAbstractType(DeserializationConfig config, JavaType type)
Method that can be called to try to resolve an abstract type (interface, abstract class) into a concrete type, or at least something "more concrete" (abstract class instead of interface).protected JavaType
BeanDeserializerFactory. materializeAbstractType(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
JsonDeserializer<?>
BeanDeserializerModifier. modifyEnumDeserializer(DeserializationConfig config, JavaType type, BeanDescription beanDesc, JsonDeserializer<?> deserializer)
Method called byBeanDeserializerFactory
after constructing default enum type deserializer instance.KeyDeserializer
BeanDeserializerModifier. modifyKeyDeserializer(DeserializationConfig config, JavaType type, KeyDeserializer deserializer)
Method called byDeserializerFactory
after it has constructed the standard key deserializer for given key type.protected JavaType
BasicDeserializerFactory. modifyTypeByAnnotation(DeserializationContext ctxt, Annotated a, JavaType type)
java.lang.Object
DefaultDeserializationContext. readRootValue(com.fasterxml.jackson.core.JsonParser p, JavaType valueType, JsonDeserializer<java.lang.Object> deser, java.lang.Object valueToUpdate)
protected JavaType
BasicDeserializerFactory. resolveMemberAndTypeAnnotations(DeserializationContext ctxt, AnnotatedMember member, JavaType type)
Helper method used to resolve additional type-related annotation information like type overrides, or handler (serializer, deserializer) overrides, so that from declared field, property or constructor parameter type is used as the base and modified based on annotations, if any.protected JavaType
BasicDeserializerFactory. resolveType(DeserializationContext ctxt, BeanDescription beanDesc, JavaType type, AnnotatedMember member)
DataFormatReaders
DataFormatReaders. withType(JavaType type)
Constructors in com.fasterxml.jackson.databind.deser with parameters of type JavaType Constructor Description Base(JavaType type)
BuilderBasedDeserializer(BeanDeserializerBuilder builder, BeanDescription beanDesc, JavaType targetType, BeanPropertyMap properties, java.util.Map<java.lang.String,SettableBeanProperty> backRefs, java.util.Set<java.lang.String> ignorableProps, boolean ignoreAllUnknown, boolean hasViews)
Constructor used byBeanDeserializerBuilder
.BuilderBasedDeserializer(BeanDeserializerBuilder builder, BeanDescription beanDesc, JavaType targetType, BeanPropertyMap properties, java.util.Map<java.lang.String,SettableBeanProperty> backRefs, java.util.Set<java.lang.String> ignorableProps, boolean ignoreAllUnknown, java.util.Set<java.lang.String> includableProps, boolean hasViews)
CreatorProperty(PropertyName name, JavaType type, PropertyName wrapperName, TypeDeserializer typeDeser, Annotations contextAnnotations, AnnotatedParameter param, int index, com.fasterxml.jackson.annotation.JacksonInject.Value injectable, PropertyMetadata metadata)
CreatorProperty(PropertyName name, JavaType type, PropertyName wrapperName, TypeDeserializer typeDeser, Annotations contextAnnotations, AnnotatedParameter param, int index, java.lang.Object injectableValueId, PropertyMetadata metadata)
Deprecated.Since 2.11 use factory method insteadSettableAnyProperty(BeanProperty property, AnnotatedMember setter, JavaType type, JsonDeserializer<java.lang.Object> valueDeser, TypeDeserializer typeDeser)
Deprecated.SettableAnyProperty(BeanProperty property, AnnotatedMember setter, JavaType type, KeyDeserializer keyDeser, JsonDeserializer<java.lang.Object> valueDeser, TypeDeserializer typeDeser)
SettableBeanProperty(BeanPropertyDefinition propDef, JavaType type, TypeDeserializer typeDeser, Annotations contextAnnotations)
SettableBeanProperty(PropertyName propName, JavaType type, PropertyMetadata metadata, JsonDeserializer<java.lang.Object> valueDeser)
Constructor only used byObjectIdValueProperty
.SettableBeanProperty(PropertyName propName, JavaType type, PropertyName wrapper, TypeDeserializer typeDeser, Annotations contextAnnotations, PropertyMetadata metadata)
-
Uses of JavaType in com.fasterxml.jackson.databind.deser.impl
Fields in com.fasterxml.jackson.databind.deser.impl declared as JavaType Modifier and Type Field Description protected JavaType
ObjectIdReader. _idType
protected JavaType
BeanAsArrayBuilderDeserializer. _targetType
Type that the builder will produce, target type; as opposed to `handledType()` which refers to Builder class.protected JavaType
NullsFailProvider. _type
protected JavaType
UnsupportedTypeDeserializer. _type
Methods in com.fasterxml.jackson.databind.deser.impl that return JavaType Modifier and Type Method Description JavaType
ObjectIdReader. getIdType()
Methods in com.fasterxml.jackson.databind.deser.impl with parameters of type JavaType Modifier and Type Method Description static ExternalTypeHandler.Builder
ExternalTypeHandler. builder(JavaType beanType)
static ObjectIdReader
ObjectIdReader. construct(JavaType idType, PropertyName propName, com.fasterxml.jackson.annotation.ObjectIdGenerator<?> generator, JsonDeserializer<?> deser, SettableBeanProperty idProp, com.fasterxml.jackson.annotation.ObjectIdResolver resolver)
Factory method called byBeanSerializerBase
with the initial information based on standard settings for the type for which serializer is being built.static NullsFailProvider
NullsFailProvider. constructForProperty(BeanProperty prop, JavaType type)
static NullsFailProvider
NullsFailProvider. constructForRootValue(JavaType t)
static JsonDeserializer<?>
JavaUtilCollectionsDeserializers. findForCollection(DeserializationContext ctxt, JavaType type)
static JsonDeserializer<?>
JavaUtilCollectionsDeserializers. findForMap(DeserializationContext ctxt, JavaType type)
Constructors in com.fasterxml.jackson.databind.deser.impl with parameters of type JavaType Constructor Description BeanAsArrayBuilderDeserializer(BeanDeserializerBase delegate, JavaType targetType, SettableBeanProperty[] ordered, AnnotatedMethod buildMethod)
Main constructor used both for creating new instances (byBeanDeserializer.asArrayDeserializer()
) and for creating copies with different delegate.Builder(JavaType t)
ExternalTypeHandler(JavaType beanType, com.fasterxml.jackson.databind.deser.impl.ExternalTypeHandler.ExtTypedProperty[] properties, java.util.Map<java.lang.String,java.lang.Object> nameToPropertyIndex, java.lang.String[] typeIds, TokenBuffer[] tokens)
FieldProperty(BeanPropertyDefinition propDef, JavaType type, TypeDeserializer typeDeser, Annotations contextAnnotations, AnnotatedField field)
MethodProperty(BeanPropertyDefinition propDef, JavaType type, TypeDeserializer typeDeser, Annotations contextAnnotations, AnnotatedMethod method)
NullsFailProvider(PropertyName name, JavaType type)
ObjectIdReader(JavaType t, PropertyName propName, com.fasterxml.jackson.annotation.ObjectIdGenerator<?> gen, JsonDeserializer<?> deser, SettableBeanProperty idProp, com.fasterxml.jackson.annotation.ObjectIdResolver resolver)
Referring(UnresolvedForwardReference ref, JavaType beanType)
SetterlessProperty(BeanPropertyDefinition propDef, JavaType type, TypeDeserializer typeDeser, Annotations contextAnnotations, AnnotatedMethod method)
UnsupportedTypeDeserializer(JavaType t, java.lang.String m)
ValueInjector(PropertyName propName, JavaType type, AnnotatedMember mutator, java.lang.Object valueId)
ValueInjector(PropertyName propName, JavaType type, Annotations contextAnnotations, AnnotatedMember mutator, java.lang.Object valueId)
Deprecated.in 2.9 (remove from 3.0) -
Uses of JavaType in com.fasterxml.jackson.databind.deser.std
Fields in com.fasterxml.jackson.databind.deser.std declared as JavaType Modifier and Type Field Description protected JavaType
StdValueInstantiator. _arrayDelegateType
protected JavaType
ContainerDeserializerBase. _containerType
protected JavaType
StdDelegatingDeserializer. _delegateType
Fully resolved delegate type, with generic information if any available.protected JavaType
StdValueInstantiator. _delegateType
protected JavaType
EnumSetDeserializer. _enumType
protected JavaType
ReferenceTypeDeserializer. _fullType
Full type of property (or root value) for which this deserializer has been constructed and contextualized.protected JavaType
UntypedObjectDeserializer. _listType
IfList
has been mapped to non-default implementation, we'll store type hereprotected JavaType
UntypedObjectDeserializer. _mapType
IfMap
has been mapped to non-default implementation, we'll store type hereprotected JavaType
StdDeserializer. _valueType
Methods in com.fasterxml.jackson.databind.deser.std that return JavaType Modifier and Type Method Description JavaType
StdValueInstantiator. getArrayDelegateType(DeserializationConfig config)
JavaType
ContainerDeserializerBase. getContentType()
Accessor for declared type of contained value elements; either exact type, or one of its supertypes.JavaType
MapEntryDeserializer. getContentType()
JavaType
StdValueInstantiator. getDelegateType(DeserializationConfig config)
JavaType
ContainerDeserializerBase. getValueType()
JavaType
MapDeserializer. getValueType()
JavaType
ReferenceTypeDeserializer. getValueType()
JavaType
StdDeserializer. getValueType()
Exact structured type this deserializer handles, if known.JavaType
StdDeserializer. getValueType(DeserializationContext ctxt)
Convenience method for getting handled type asJavaType
, regardless of whether deserializer has one already resolved (and accessible viaStdDeserializer.getValueType()
) or not: equivalent to:Methods in com.fasterxml.jackson.databind.deser.std with parameters of type JavaType Modifier and Type Method Description protected JsonDeserializer<java.lang.Object>
UntypedObjectDeserializer. _findCustomDeser(DeserializationContext ctxt, JavaType type)
protected boolean
MapDeserializer. _isStdKeyDeser(JavaType mapType, KeyDeserializer keyDeser)
Helper method used to check whether we can just use the default key deserialization, where JSON String becomes Java String.void
StdValueInstantiator. configureFromArraySettings(AnnotatedWithParams arrayDelegateCreator, JavaType arrayDelegateType, SettableBeanProperty[] arrayDelegateArgs)
void
StdValueInstantiator. configureFromObjectSettings(AnnotatedWithParams defaultCreator, AnnotatedWithParams delegateCreator, JavaType delegateType, SettableBeanProperty[] delegateArgs, AnnotatedWithParams withArgsCreator, SettableBeanProperty[] constructorArgs)
Method for setting properties related to instantiating values from JSON Object.static KeyDeserializer
StdKeyDeserializers. constructDelegatingKeyDeserializer(DeserializationConfig config, JavaType type, JsonDeserializer<?> deser)
protected JsonDeserializer<java.lang.Object>
StdDeserializer. findDeserializer(DeserializationContext ctxt, JavaType type, BeanProperty property)
Helper method used to locate deserializers for properties the type this deserializer handles contains (usually for properties of bean types)KeyDeserializer
StdKeyDeserializers. findKeyDeserializer(JavaType type, DeserializationConfig config, BeanDescription beanDesc)
static KeyDeserializer
StdKeyDeserializers. findStringBasedKeyDeserializer(DeserializationConfig config, JavaType type)
protected StdDelegatingDeserializer<T>
StdDelegatingDeserializer. withDelegate(Converter<java.lang.Object,T> converter, JavaType delegateType, JsonDeserializer<?> delegateDeserializer)
Method used for creating resolved contextual instances.Constructors in com.fasterxml.jackson.databind.deser.std with parameters of type JavaType Constructor Description ArrayBlockingQueueDeserializer(JavaType containerType, JsonDeserializer<java.lang.Object> valueDeser, TypeDeserializer valueTypeDeser, ValueInstantiator valueInstantiator)
ArrayBlockingQueueDeserializer(JavaType containerType, JsonDeserializer<java.lang.Object> valueDeser, TypeDeserializer valueTypeDeser, ValueInstantiator valueInstantiator, JsonDeserializer<java.lang.Object> delegateDeser, NullValueProvider nuller, java.lang.Boolean unwrapSingle)
Constructor used when creating contextualized instances.AtomicReferenceDeserializer(JavaType fullType, ValueInstantiator inst, TypeDeserializer typeDeser, JsonDeserializer<?> deser)
CollectionDeserializer(JavaType collectionType, JsonDeserializer<java.lang.Object> valueDeser, TypeDeserializer valueTypeDeser, ValueInstantiator valueInstantiator)
Constructor for context-free instances, where we do not yet know which property is using this deserializer.CollectionDeserializer(JavaType collectionType, JsonDeserializer<java.lang.Object> valueDeser, TypeDeserializer valueTypeDeser, ValueInstantiator valueInstantiator, JsonDeserializer<java.lang.Object> delegateDeser, NullValueProvider nuller, java.lang.Boolean unwrapSingle)
Constructor used when creating contextualized instances.ContainerDeserializerBase(JavaType selfType)
ContainerDeserializerBase(JavaType selfType, NullValueProvider nuller, java.lang.Boolean unwrapSingle)
EnumMapDeserializer(JavaType mapType, ValueInstantiator valueInst, KeyDeserializer keyDeser, JsonDeserializer<?> valueDeser, TypeDeserializer vtd, NullValueProvider nuller)
EnumMapDeserializer(JavaType mapType, KeyDeserializer keyDeser, JsonDeserializer<?> valueDeser, TypeDeserializer vtd)
Deprecated.EnumSetDeserializer(JavaType enumType, JsonDeserializer<?> deser)
MapDeserializer(JavaType mapType, ValueInstantiator valueInstantiator, KeyDeserializer keyDeser, JsonDeserializer<java.lang.Object> valueDeser, TypeDeserializer valueTypeDeser)
MapEntryDeserializer(JavaType type, KeyDeserializer keyDeser, JsonDeserializer<java.lang.Object> valueDeser, TypeDeserializer valueTypeDeser)
ObjectArrayDeserializer(JavaType arrayType0, JsonDeserializer<java.lang.Object> elemDeser, TypeDeserializer elemTypeDeser)
ReferenceTypeDeserializer(JavaType fullType, ValueInstantiator vi, TypeDeserializer typeDeser, JsonDeserializer<?> deser)
ReferenceTypeDeserializer(JavaType fullType, TypeDeserializer typeDeser, JsonDeserializer<?> deser)
Deprecated.StdDelegatingDeserializer(Converter<java.lang.Object,T> converter, JavaType delegateType, JsonDeserializer<?> delegateDeserializer)
StdDeserializer(JavaType valueType)
StdNodeBasedDeserializer(JavaType targetType)
StdScalarDeserializer(JavaType valueType)
StdValueInstantiator(DeserializationConfig config, JavaType valueType)
StringCollectionDeserializer(JavaType collectionType, ValueInstantiator valueInstantiator, JsonDeserializer<?> delegateDeser, JsonDeserializer<?> valueDeser, NullValueProvider nuller, java.lang.Boolean unwrapSingle)
StringCollectionDeserializer(JavaType collectionType, JsonDeserializer<?> valueDeser, ValueInstantiator valueInstantiator)
UntypedObjectDeserializer(JavaType listType, JavaType mapType)
-
Uses of JavaType in com.fasterxml.jackson.databind.exc
Fields in com.fasterxml.jackson.databind.exc declared as JavaType Modifier and Type Field Description protected JavaType
InvalidTypeIdException. _baseType
Basetype for which subtype was to be resolvedprotected JavaType
InvalidDefinitionException. _type
protected JavaType
ValueInstantiationException. _type
Methods in com.fasterxml.jackson.databind.exc that return JavaType Modifier and Type Method Description JavaType
InvalidTypeIdException. getBaseType()
JavaType
InvalidDefinitionException. getType()
Accessor for type fully resolved type that had the problem; this should always known and available, nevernull
JavaType
ValueInstantiationException. getType()
Accessor for type fully resolved type that had the problem; this should always known and available, nevernull
Methods in com.fasterxml.jackson.databind.exc with parameters of type JavaType Modifier and Type Method Description static InvalidDefinitionException
InvalidDefinitionException. from(com.fasterxml.jackson.core.JsonGenerator g, java.lang.String msg, JavaType type)
static InvalidDefinitionException
InvalidDefinitionException. from(com.fasterxml.jackson.core.JsonParser p, java.lang.String msg, JavaType type)
static InvalidNullException
InvalidNullException. from(DeserializationContext ctxt, PropertyName name, JavaType type)
static InvalidTypeIdException
InvalidTypeIdException. from(com.fasterxml.jackson.core.JsonParser p, java.lang.String msg, JavaType baseType, java.lang.String typeId)
static MismatchedInputException
MismatchedInputException. from(com.fasterxml.jackson.core.JsonParser p, JavaType targetType, java.lang.String msg)
static ValueInstantiationException
ValueInstantiationException. from(com.fasterxml.jackson.core.JsonParser p, java.lang.String msg, JavaType type)
static ValueInstantiationException
ValueInstantiationException. from(com.fasterxml.jackson.core.JsonParser p, java.lang.String msg, JavaType type, java.lang.Throwable cause)
MismatchedInputException
MismatchedInputException. setTargetType(JavaType t)
Constructors in com.fasterxml.jackson.databind.exc with parameters of type JavaType Constructor Description InvalidDefinitionException(com.fasterxml.jackson.core.JsonGenerator g, java.lang.String msg, JavaType type)
InvalidDefinitionException(com.fasterxml.jackson.core.JsonParser p, java.lang.String msg, JavaType type)
InvalidTypeIdException(com.fasterxml.jackson.core.JsonParser p, java.lang.String msg, JavaType baseType, java.lang.String typeId)
MismatchedInputException(com.fasterxml.jackson.core.JsonParser p, java.lang.String msg, JavaType targetType)
ValueInstantiationException(com.fasterxml.jackson.core.JsonParser p, java.lang.String msg, JavaType type)
ValueInstantiationException(com.fasterxml.jackson.core.JsonParser p, java.lang.String msg, JavaType type, java.lang.Throwable cause)
-
Uses of JavaType in com.fasterxml.jackson.databind.ext
Methods in com.fasterxml.jackson.databind.ext with parameters of type JavaType Modifier and Type Method Description void
CoreXMLSerializers.XMLGregorianCalendarSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
DOMSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
SqlBlobSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
JsonDeserializer<?>
CoreXMLDeserializers. findBeanDeserializer(JavaType type, DeserializationConfig config, BeanDescription beanDesc)
JsonDeserializer<?>
OptionalHandlerFactory. findDeserializer(JavaType type, DeserializationConfig config, BeanDescription beanDesc)
JsonSerializer<?>
CoreXMLSerializers. findSerializer(SerializationConfig config, JavaType type, BeanDescription beanDesc)
JsonSerializer<?>
OptionalHandlerFactory. findSerializer(SerializationConfig config, JavaType type, BeanDescription beanDesc)
-
Uses of JavaType in com.fasterxml.jackson.databind.introspect
Fields in com.fasterxml.jackson.databind.introspect declared as JavaType Modifier and Type Field Description protected JavaType
AnnotatedClass. _type
protected JavaType
AnnotatedParameter. _type
JDK type of the parameter, possibly contains generic type informationprotected JavaType
POJOPropertiesCollector. _type
Type of POJO for which properties are being collected.protected JavaType
VirtualAnnotatedMember. _type
Fields in com.fasterxml.jackson.databind.introspect with type parameters of type JavaType Modifier and Type Field Description protected java.util.List<JavaType>
AnnotatedClass. _superTypes
Ordered set of super classes and interfaces of the class itself: included in order of precedenceMethods in com.fasterxml.jackson.databind.introspect that return JavaType Modifier and Type Method Description JavaType
AnnotatedConstructor. getParameterType(int index)
JavaType
AnnotatedMethod. getParameterType(int index)
abstract JavaType
AnnotatedWithParams. getParameterType(int index)
abstract JavaType
BeanPropertyDefinition. getPrimaryType()
JavaType
POJOPropertyBuilder. getPrimaryType()
Type determined from the primary member for the property being built, considering precedence according to whether we are processing serialization or deserialization.abstract JavaType
Annotated. getType()
Full generic type of the annotated element; definition of what exactly this means depends on sub-class.JavaType
AnnotatedClass. getType()
JavaType
AnnotatedConstructor. getType()
JavaType
AnnotatedField. getType()
JavaType
AnnotatedMethod. getType()
For methods, this returns declared return type, which is only useful with getters (setters do not return anything; hence `Void` would be returned here)JavaType
AnnotatedParameter. getType()
JavaType
POJOPropertiesCollector. getType()
JavaType
VirtualAnnotatedMember. getType()
JavaType
AnnotationIntrospectorPair. refineDeserializationType(MapperConfig<?> config, Annotated a, JavaType baseType)
JavaType
JacksonAnnotationIntrospector. refineDeserializationType(MapperConfig<?> config, Annotated a, JavaType baseType)
JavaType
AnnotationIntrospectorPair. refineSerializationType(MapperConfig<?> config, Annotated a, JavaType baseType)
JavaType
JacksonAnnotationIntrospector. refineSerializationType(MapperConfig<?> config, Annotated a, JavaType baseType)
JavaType
AnnotatedClass. resolveType(java.lang.reflect.Type type)
JavaType
BasicBeanDescription. resolveType(java.lang.reflect.Type jdkType)
Deprecated.JavaType
TypeResolutionContext.Basic. resolveType(java.lang.reflect.Type type)
JavaType
TypeResolutionContext.Empty. resolveType(java.lang.reflect.Type type)
JavaType
TypeResolutionContext. resolveType(java.lang.reflect.Type t)
Methods in com.fasterxml.jackson.databind.introspect with parameters of type JavaType Modifier and Type Method Description protected BeanPropertyWriter
JacksonAnnotationIntrospector. _constructVirtualProperty(JsonAppend.Attr attr, MapperConfig<?> config, AnnotatedClass ac, JavaType type)
protected BasicBeanDescription
BasicClassIntrospector. _findStdJdkCollectionDesc(MapperConfig<?> cfg, JavaType type)
protected BasicBeanDescription
BasicClassIntrospector. _findStdTypeDesc(MapperConfig<?> config, JavaType type)
Method called to see if type is one of core JDK types that we have cached for efficiency.protected TypeResolverBuilder<?>
JacksonAnnotationIntrospector. _findTypeResolver(MapperConfig<?> config, Annotated ann, JavaType baseType)
Helper method called to construct and initialize instance ofTypeResolverBuilder
if given annotated element indicates one is needed.protected boolean
BasicClassIntrospector. _isStdJDKCollection(JavaType type)
Helper method used to decide whether we can omit introspection for members (methods, fields, constructors); we may do so for a limited number of container types JDK provides.protected AnnotatedClass
BasicClassIntrospector. _resolveAnnotatedClass(MapperConfig<?> config, JavaType type, ClassIntrospector.MixInResolver r)
protected AnnotatedClass
BasicClassIntrospector. _resolveAnnotatedWithoutSuperTypes(MapperConfig<?> config, JavaType type, ClassIntrospector.MixInResolver r)
static java.util.List<AnnotatedField>
AnnotatedFieldCollector. collectFields(AnnotationIntrospector intr, TypeResolutionContext tc, ClassIntrospector.MixInResolver mixins, TypeFactory types, JavaType type, boolean collectAnnotations)
static AnnotatedMethodMap
AnnotatedMethodCollector. collectMethods(AnnotationIntrospector intr, TypeResolutionContext tc, ClassIntrospector.MixInResolver mixins, TypeFactory types, JavaType type, java.util.List<JavaType> superTypes, java.lang.Class<?> primaryMixIn, boolean collectAnnotations)
protected POJOPropertiesCollector
BasicClassIntrospector. collectProperties(MapperConfig<?> config, JavaType type, ClassIntrospector.MixInResolver r, boolean forSerialization)
protected POJOPropertiesCollector
BasicClassIntrospector. collectProperties(MapperConfig<?> config, JavaType type, ClassIntrospector.MixInResolver r, boolean forSerialization, java.lang.String mutatorPrefix)
Deprecated.protected POJOPropertiesCollector
BasicClassIntrospector. collectPropertiesWithBuilder(MapperConfig<?> config, JavaType type, ClassIntrospector.MixInResolver r, boolean forSerialization)
Deprecated.protected POJOPropertiesCollector
BasicClassIntrospector. collectPropertiesWithBuilder(MapperConfig<?> config, JavaType type, ClassIntrospector.MixInResolver r, BeanDescription valueTypeDesc, boolean forSerialization)
static AnnotatedClass
AnnotatedClass. construct(JavaType type, MapperConfig<?> config)
Deprecated.Since 2.9, use methods inAnnotatedClassResolver
instead.static AnnotatedClass
AnnotatedClass. construct(JavaType type, MapperConfig<?> config, ClassIntrospector.MixInResolver mir)
Deprecated.Since 2.9, use methods inAnnotatedClassResolver
instead.protected POJOPropertiesCollector
BasicClassIntrospector. constructPropertyCollector(MapperConfig<?> config, AnnotatedClass classDef, JavaType type, boolean forSerialization, AccessorNamingStrategy accNaming)
Overridable method called for creatingPOJOPropertiesCollector
instance to use; override is needed if a custom sub-class is to be used.protected POJOPropertiesCollector
BasicClassIntrospector. constructPropertyCollector(MapperConfig<?> config, AnnotatedClass ac, JavaType type, boolean forSerialization, java.lang.String mutatorPrefix)
Deprecated.java.lang.Class<?>
AnnotationIntrospectorPair. findDeserializationContentType(Annotated am, JavaType baseContentType)
Deprecated.java.lang.Class<?>
JacksonAnnotationIntrospector. findDeserializationContentType(Annotated am, JavaType baseContentType)
Deprecated.java.lang.Class<?>
AnnotationIntrospectorPair. findDeserializationKeyType(Annotated am, JavaType baseKeyType)
Deprecated.java.lang.Class<?>
JacksonAnnotationIntrospector. findDeserializationKeyType(Annotated am, JavaType baseKeyType)
Deprecated.java.lang.Class<?>
AnnotationIntrospectorPair. findDeserializationType(Annotated am, JavaType baseType)
Deprecated.java.lang.Class<?>
JacksonAnnotationIntrospector. findDeserializationType(Annotated am, JavaType baseType)
Deprecated.TypeResolverBuilder<?>
AnnotationIntrospectorPair. findPropertyContentTypeResolver(MapperConfig<?> config, AnnotatedMember am, JavaType baseType)
TypeResolverBuilder<?>
JacksonAnnotationIntrospector. findPropertyContentTypeResolver(MapperConfig<?> config, AnnotatedMember am, JavaType containerType)
TypeResolverBuilder<?>
AnnotationIntrospectorPair. findPropertyTypeResolver(MapperConfig<?> config, AnnotatedMember am, JavaType baseType)
TypeResolverBuilder<?>
JacksonAnnotationIntrospector. findPropertyTypeResolver(MapperConfig<?> config, AnnotatedMember am, JavaType baseType)
java.lang.Class<?>
AnnotationIntrospectorPair. findSerializationContentType(Annotated am, JavaType baseType)
Deprecated.java.lang.Class<?>
JacksonAnnotationIntrospector. findSerializationContentType(Annotated am, JavaType baseType)
Deprecated.java.lang.Class<?>
AnnotationIntrospectorPair. findSerializationKeyType(Annotated am, JavaType baseType)
Deprecated.java.lang.Class<?>
JacksonAnnotationIntrospector. findSerializationKeyType(Annotated am, JavaType baseType)
Deprecated.TypeResolverBuilder<?>
AnnotationIntrospectorPair. findTypeResolver(MapperConfig<?> config, AnnotatedClass ac, JavaType baseType)
TypeResolverBuilder<?>
JacksonAnnotationIntrospector. findTypeResolver(MapperConfig<?> config, AnnotatedClass ac, JavaType baseType)
BasicBeanDescription
BasicClassIntrospector. forClassAnnotations(MapperConfig<?> config, JavaType type, ClassIntrospector.MixInResolver r)
abstract BeanDescription
ClassIntrospector. forClassAnnotations(MapperConfig<?> cfg, JavaType type, ClassIntrospector.MixInResolver r)
Factory method that constructs an introspector that only has information regarding annotations class itself (or its supertypes) has, but nothing on methods or constructors.BasicBeanDescription
BasicClassIntrospector. forCreation(DeserializationConfig config, JavaType type, ClassIntrospector.MixInResolver r)
abstract BeanDescription
ClassIntrospector. forCreation(DeserializationConfig cfg, JavaType type, ClassIntrospector.MixInResolver r)
Factory method that constructs an introspector that has information necessary for creating instances of given class ("creator"), as well as class annotations, but no information on member methodsBasicBeanDescription
BasicClassIntrospector. forDeserialization(DeserializationConfig config, JavaType type, ClassIntrospector.MixInResolver r)
abstract BeanDescription
ClassIntrospector. forDeserialization(DeserializationConfig cfg, JavaType type, ClassIntrospector.MixInResolver r)
Factory method that constructs an introspector that has all information needed for deserialization purposes.BasicBeanDescription
BasicClassIntrospector. forDeserializationWithBuilder(DeserializationConfig config, JavaType type, ClassIntrospector.MixInResolver r)
Deprecated.BasicBeanDescription
BasicClassIntrospector. forDeserializationWithBuilder(DeserializationConfig config, JavaType builderType, ClassIntrospector.MixInResolver r, BeanDescription valueTypeDesc)
abstract BeanDescription
ClassIntrospector. forDeserializationWithBuilder(DeserializationConfig cfg, JavaType builderType, ClassIntrospector.MixInResolver r)
Deprecated.Since 2.12 use overload that take value type descriptionabstract BeanDescription
ClassIntrospector. forDeserializationWithBuilder(DeserializationConfig cfg, JavaType builderType, ClassIntrospector.MixInResolver r, BeanDescription valueTypeDesc)
Factory method that constructs an introspector that has all information needed for constructing deserializers that use intermediate Builder objects.BasicBeanDescription
BasicClassIntrospector. forDirectClassAnnotations(MapperConfig<?> config, JavaType type, ClassIntrospector.MixInResolver r)
abstract BeanDescription
ClassIntrospector. forDirectClassAnnotations(MapperConfig<?> cfg, JavaType type, ClassIntrospector.MixInResolver r)
Factory method that constructs an introspector that only has information regarding annotations class itself has (but NOT including its supertypes), but nothing on methods or constructors.static BasicBeanDescription
BasicBeanDescription. forOtherUse(MapperConfig<?> config, JavaType type, AnnotatedClass ac)
Factory method to use for constructing an instance to use for purposes other than building serializers or deserializers; will only have information on class, not on properties.BasicBeanDescription
BasicClassIntrospector. forSerialization(SerializationConfig config, JavaType type, ClassIntrospector.MixInResolver r)
abstract BeanDescription
ClassIntrospector. forSerialization(SerializationConfig cfg, JavaType type, ClassIntrospector.MixInResolver r)
Factory method that constructs an introspector that has all information needed for serialization purposes.JavaType
AnnotationIntrospectorPair. refineDeserializationType(MapperConfig<?> config, Annotated a, JavaType baseType)
JavaType
JacksonAnnotationIntrospector. refineDeserializationType(MapperConfig<?> config, Annotated a, JavaType baseType)
JavaType
AnnotationIntrospectorPair. refineSerializationType(MapperConfig<?> config, Annotated a, JavaType baseType)
JavaType
JacksonAnnotationIntrospector. refineSerializationType(MapperConfig<?> config, Annotated a, JavaType baseType)
static AnnotatedClass
AnnotatedClassResolver. resolve(MapperConfig<?> config, JavaType forType, ClassIntrospector.MixInResolver r)
static AnnotatedClass
AnnotatedClassResolver. resolveWithoutSuperTypes(MapperConfig<?> config, JavaType forType, ClassIntrospector.MixInResolver r)
Method parameters in com.fasterxml.jackson.databind.introspect with type arguments of type JavaType Modifier and Type Method Description static AnnotatedMethodMap
AnnotatedMethodCollector. collectMethods(AnnotationIntrospector intr, TypeResolutionContext tc, ClassIntrospector.MixInResolver mixins, TypeFactory types, JavaType type, java.util.List<JavaType> superTypes, java.lang.Class<?> primaryMixIn, boolean collectAnnotations)
Constructors in com.fasterxml.jackson.databind.introspect with parameters of type JavaType Constructor Description AnnotatedParameter(AnnotatedWithParams owner, JavaType type, TypeResolutionContext typeContext, AnnotationMap annotations, int index)
BasicBeanDescription(MapperConfig<?> config, JavaType type, AnnotatedClass classDef, java.util.List<BeanPropertyDefinition> props)
Alternate constructor used in cases where property information is not needed, only class info.BasicBeanDescription(POJOPropertiesCollector coll, JavaType type, AnnotatedClass classDef)
POJOPropertiesCollector(MapperConfig<?> config, boolean forSerialization, JavaType type, AnnotatedClass classDef, AccessorNamingStrategy accessorNaming)
POJOPropertiesCollector(MapperConfig<?> config, boolean forSerialization, JavaType type, AnnotatedClass classDef, java.lang.String mutatorPrefix)
Deprecated.Since 2.12VirtualAnnotatedMember(TypeResolutionContext typeContext, java.lang.Class<?> declaringClass, java.lang.String name, JavaType type)
-
Uses of JavaType in com.fasterxml.jackson.databind.jsonFormatVisitors
Methods in com.fasterxml.jackson.databind.jsonFormatVisitors with parameters of type JavaType Modifier and Type Method Description void
JsonFormatVisitable. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
Get the representation of the schema to which this serializer will conform.JsonAnyFormatVisitor
JsonFormatVisitorWrapper.Base. expectAnyFormat(JavaType type)
JsonAnyFormatVisitor
JsonFormatVisitorWrapper. expectAnyFormat(JavaType type)
JsonArrayFormatVisitor
JsonFormatVisitorWrapper.Base. expectArrayFormat(JavaType type)
JsonArrayFormatVisitor
JsonFormatVisitorWrapper. expectArrayFormat(JavaType type)
JsonBooleanFormatVisitor
JsonFormatVisitorWrapper.Base. expectBooleanFormat(JavaType type)
JsonBooleanFormatVisitor
JsonFormatVisitorWrapper. expectBooleanFormat(JavaType type)
JsonIntegerFormatVisitor
JsonFormatVisitorWrapper.Base. expectIntegerFormat(JavaType type)
JsonIntegerFormatVisitor
JsonFormatVisitorWrapper. expectIntegerFormat(JavaType type)
JsonMapFormatVisitor
JsonFormatVisitorWrapper.Base. expectMapFormat(JavaType type)
JsonMapFormatVisitor
JsonFormatVisitorWrapper. expectMapFormat(JavaType type)
Method called when type is of JavaMap
type, and will be serialized as a JSON Object.JsonNullFormatVisitor
JsonFormatVisitorWrapper.Base. expectNullFormat(JavaType type)
JsonNullFormatVisitor
JsonFormatVisitorWrapper. expectNullFormat(JavaType type)
JsonNumberFormatVisitor
JsonFormatVisitorWrapper.Base. expectNumberFormat(JavaType type)
JsonNumberFormatVisitor
JsonFormatVisitorWrapper. expectNumberFormat(JavaType type)
JsonObjectFormatVisitor
JsonFormatVisitorWrapper.Base. expectObjectFormat(JavaType type)
JsonObjectFormatVisitor
JsonFormatVisitorWrapper. expectObjectFormat(JavaType type)
JsonStringFormatVisitor
JsonFormatVisitorWrapper.Base. expectStringFormat(JavaType type)
JsonStringFormatVisitor
JsonFormatVisitorWrapper. expectStringFormat(JavaType type)
void
JsonArrayFormatVisitor.Base. itemsFormat(JsonFormatVisitable handler, JavaType elementType)
void
JsonArrayFormatVisitor. itemsFormat(JsonFormatVisitable handler, JavaType elementType)
Visit method called for structured types, as well as possibly for leaf types (especially if handled by custom serializers).void
JsonMapFormatVisitor.Base. keyFormat(JsonFormatVisitable handler, JavaType keyType)
void
JsonMapFormatVisitor. keyFormat(JsonFormatVisitable handler, JavaType keyType)
Visit method called to indicate type of keys of the Map type being visitedvoid
JsonObjectFormatVisitor.Base. optionalProperty(java.lang.String name, JsonFormatVisitable handler, JavaType propertyTypeHint)
void
JsonObjectFormatVisitor. optionalProperty(java.lang.String name, JsonFormatVisitable handler, JavaType propertyTypeHint)
void
JsonObjectFormatVisitor.Base. property(java.lang.String name, JsonFormatVisitable handler, JavaType propertyTypeHint)
void
JsonObjectFormatVisitor. property(java.lang.String name, JsonFormatVisitable handler, JavaType propertyTypeHint)
Callback method called when a non-POJO property (typically something like an Enum entry ofEnumMap
type) is being traversed.void
JsonMapFormatVisitor.Base. valueFormat(JsonFormatVisitable handler, JavaType valueType)
void
JsonMapFormatVisitor. valueFormat(JsonFormatVisitable handler, JavaType valueType)
Visit method called afterJsonMapFormatVisitor.keyFormat(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitable, com.fasterxml.jackson.databind.JavaType)
to allow visiting of the value type -
Uses of JavaType in com.fasterxml.jackson.databind.jsontype
Methods in com.fasterxml.jackson.databind.jsontype that return JavaType Modifier and Type Method Description JavaType
TypeIdResolver. typeFromId(DatabindContext context, java.lang.String id)
Method called to resolve type from given type identifier.Methods in com.fasterxml.jackson.databind.jsontype with parameters of type JavaType Modifier and Type Method Description TypeDeserializer
TypeResolverBuilder. buildTypeDeserializer(DeserializationConfig config, JavaType baseType, java.util.Collection<NamedType> subtypes)
Method for building type deserializer based on current configuration of this builder.TypeSerializer
TypeResolverBuilder. buildTypeSerializer(SerializationConfig config, JavaType baseType, java.util.Collection<NamedType> subtypes)
Method for building type serializer based on current configuration of this builder.java.util.Collection<NamedType>
SubtypeResolver. collectAndResolveSubtypes(AnnotatedMember property, MapperConfig<?> config, AnnotationIntrospector ai, JavaType baseType)
Deprecated.java.util.Collection<NamedType>
SubtypeResolver. collectAndResolveSubtypesByClass(MapperConfig<?> config, AnnotatedMember property, JavaType baseType)
Method for finding out all reachable subtypes for a property specified by given element (method or field), such that access is by type, typically needed for serialization (converting from type to type name).java.util.Collection<NamedType>
SubtypeResolver. collectAndResolveSubtypesByTypeId(MapperConfig<?> config, AnnotatedMember property, JavaType baseType)
Method for finding out all reachable subtypes for a property specified by given element (method or field), such that access is by type id, typically needed for deserialization (converting from type id to type).static java.lang.Object
TypeDeserializer. deserializeIfNatural(com.fasterxml.jackson.core.JsonParser p, DeserializationContext ctxt, JavaType baseType)
Helper method used to check if given parser might be pointing to a "natural" value, and one that would be acceptable as the result value (compatible with declared base type)void
TypeIdResolver. init(JavaType baseType)
Method that will be called once before any type resolution calls; used to initialize instance with configuration.protected boolean
DefaultBaseTypeLimitingValidator. isSafeSubType(MapperConfig<?> config, JavaType baseType, JavaType subType)
Helper called to determine whether given actual subtype is considered safe to process: this will only be called if subtype was considered acceptable earlier.protected boolean
DefaultBaseTypeLimitingValidator. isUnsafeBaseType(MapperConfig<?> config, JavaType baseType)
Helper method called to determine if the given base type is known to be problematic regarding possible "gadget types".PolymorphicTypeValidator.Validity
BasicPolymorphicTypeValidator. validateBaseType(MapperConfig<?> ctxt, JavaType baseType)
PolymorphicTypeValidator.Validity
DefaultBaseTypeLimitingValidator. validateBaseType(MapperConfig<?> config, JavaType baseType)
PolymorphicTypeValidator.Validity
PolymorphicTypeValidator.Base. validateBaseType(MapperConfig<?> config, JavaType baseType)
abstract PolymorphicTypeValidator.Validity
PolymorphicTypeValidator. validateBaseType(MapperConfig<?> config, JavaType baseType)
Method called when a property with polymorphic value is encountered, and aTypeResolverBuilder
is needed.PolymorphicTypeValidator.Validity
BasicPolymorphicTypeValidator. validateSubClassName(MapperConfig<?> ctxt, JavaType baseType, java.lang.String subClassName)
PolymorphicTypeValidator.Validity
DefaultBaseTypeLimitingValidator. validateSubClassName(MapperConfig<?> config, JavaType baseType, java.lang.String subClassName)
PolymorphicTypeValidator.Validity
PolymorphicTypeValidator.Base. validateSubClassName(MapperConfig<?> config, JavaType baseType, java.lang.String subClassName)
abstract PolymorphicTypeValidator.Validity
PolymorphicTypeValidator. validateSubClassName(MapperConfig<?> config, JavaType baseType, java.lang.String subClassName)
Method called after intended class name for subtype has been read (and in case of minimal class name, expanded to fully-qualified class name) but before attempt is made to look up actualClass
orJavaType
.PolymorphicTypeValidator.Validity
BasicPolymorphicTypeValidator. validateSubType(MapperConfig<?> ctxt, JavaType baseType, JavaType subType)
PolymorphicTypeValidator.Validity
DefaultBaseTypeLimitingValidator. validateSubType(MapperConfig<?> config, JavaType baseType, JavaType subType)
PolymorphicTypeValidator.Validity
PolymorphicTypeValidator.Base. validateSubType(MapperConfig<?> config, JavaType baseType, JavaType subType)
abstract PolymorphicTypeValidator.Validity
PolymorphicTypeValidator. validateSubType(MapperConfig<?> config, JavaType baseType, JavaType subType)
Method called after class name has been resolved to actual type, in cases where previous call toPolymorphicTypeValidator.validateSubClassName(com.fasterxml.jackson.databind.cfg.MapperConfig<?>, com.fasterxml.jackson.databind.JavaType, java.lang.String)
returnedPolymorphicTypeValidator.Validity.INDETERMINATE
. -
Uses of JavaType in com.fasterxml.jackson.databind.jsontype.impl
Fields in com.fasterxml.jackson.databind.jsontype.impl declared as JavaType Modifier and Type Field Description protected JavaType
TypeDeserializerBase. _baseType
protected JavaType
TypeIdResolverBase. _baseType
Common base type for all polymorphic instances handled.protected JavaType
TypeDeserializerBase. _defaultImpl
Type to use as the default implementation, if type id is missing or cannot be resolved.Fields in com.fasterxml.jackson.databind.jsontype.impl with type parameters of type JavaType Modifier and Type Field Description protected java.util.Map<java.lang.String,JavaType>
TypeNameIdResolver. _idToType
Mappings from type id to JavaType, used for deserialization.Methods in com.fasterxml.jackson.databind.jsontype.impl that return JavaType Modifier and Type Method Description protected JavaType
TypeDeserializerBase. _handleMissingTypeId(DeserializationContext ctxt, java.lang.String extraDesc)
protected JavaType
TypeDeserializerBase. _handleUnknownTypeId(DeserializationContext ctxt, java.lang.String typeId)
Helper method called when given type id cannot be resolved into concrete deserializer either directly (using givenTypeIdResolver
), or using default type.protected JavaType
ClassNameIdResolver. _typeFromId(java.lang.String id, DatabindContext ctxt)
protected JavaType
MinimalClassNameIdResolver. _typeFromId(java.lang.String id, DatabindContext ctxt)
protected JavaType
TypeNameIdResolver. _typeFromId(java.lang.String id)
JavaType
TypeDeserializerBase. baseType()
protected JavaType
StdTypeResolverBuilder. defineDefaultImpl(DeserializationConfig config, JavaType baseType)
JavaType
ClassNameIdResolver. typeFromId(DatabindContext context, java.lang.String id)
JavaType
TypeIdResolverBase. typeFromId(DatabindContext context, java.lang.String id)
JavaType
TypeNameIdResolver. typeFromId(DatabindContext context, java.lang.String id)
Methods in com.fasterxml.jackson.databind.jsontype.impl with parameters of type JavaType Modifier and Type Method Description protected boolean
StdTypeResolverBuilder. allowPrimitiveTypes(MapperConfig<?> config, JavaType baseType)
Overridable helper method that is called to determine whether type serializers and type deserializers may be created even if base type is Javaprimitive
type.TypeDeserializer
StdTypeResolverBuilder. buildTypeDeserializer(DeserializationConfig config, JavaType baseType, java.util.Collection<NamedType> subtypes)
TypeSerializer
StdTypeResolverBuilder. buildTypeSerializer(SerializationConfig config, JavaType baseType, java.util.Collection<NamedType> subtypes)
java.util.Collection<NamedType>
StdSubtypeResolver. collectAndResolveSubtypesByClass(MapperConfig<?> config, AnnotatedMember property, JavaType baseType)
java.util.Collection<NamedType>
StdSubtypeResolver. collectAndResolveSubtypesByTypeId(MapperConfig<?> config, AnnotatedMember property, JavaType baseType)
static ClassNameIdResolver
ClassNameIdResolver. construct(JavaType baseType, MapperConfig<?> config, PolymorphicTypeValidator ptv)
static MinimalClassNameIdResolver
MinimalClassNameIdResolver. construct(JavaType baseType, MapperConfig<?> config, PolymorphicTypeValidator ptv)
static TypeNameIdResolver
TypeNameIdResolver. construct(MapperConfig<?> config, JavaType baseType, java.util.Collection<NamedType> subtypes, boolean forSer, boolean forDeser)
protected JavaType
StdTypeResolverBuilder. defineDefaultImpl(DeserializationConfig config, JavaType baseType)
protected TypeIdResolver
StdTypeResolverBuilder. idResolver(MapperConfig<?> config, JavaType baseType, PolymorphicTypeValidator subtypeValidator, java.util.Collection<NamedType> subtypes, boolean forSer, boolean forDeser)
Helper method that will either return configured custom type id resolver, or construct a standard resolver given configuration.void
TypeIdResolverBase. init(JavaType bt)
protected PolymorphicTypeValidator
StdTypeResolverBuilder. reportInvalidBaseType(MapperConfig<?> config, JavaType baseType, PolymorphicTypeValidator ptv)
PolymorphicTypeValidator.Validity
LaissezFaireSubTypeValidator. validateBaseType(MapperConfig<?> ctxt, JavaType baseType)
PolymorphicTypeValidator.Validity
LaissezFaireSubTypeValidator. validateSubClassName(MapperConfig<?> ctxt, JavaType baseType, java.lang.String subClassName)
PolymorphicTypeValidator.Validity
LaissezFaireSubTypeValidator. validateSubType(MapperConfig<?> ctxt, JavaType baseType, JavaType subType)
void
SubTypeValidator. validateSubType(DeserializationContext ctxt, JavaType type, BeanDescription beanDesc)
protected PolymorphicTypeValidator
StdTypeResolverBuilder. verifyBaseTypeValidity(MapperConfig<?> config, JavaType baseType)
Helper method called to check that base type is valid regarding possible constraints on basetype/subtype combinations allowed for polymorphic type handling.Constructors in com.fasterxml.jackson.databind.jsontype.impl with parameters of type JavaType Constructor Description AsArrayTypeDeserializer(JavaType bt, TypeIdResolver idRes, java.lang.String typePropertyName, boolean typeIdVisible, JavaType defaultImpl)
AsDeductionTypeDeserializer(JavaType bt, TypeIdResolver idRes, JavaType defaultImpl, DeserializationConfig config, java.util.Collection<NamedType> subtypes)
AsExternalTypeDeserializer(JavaType bt, TypeIdResolver idRes, java.lang.String typePropertyName, boolean typeIdVisible, JavaType defaultImpl)
AsPropertyTypeDeserializer(JavaType bt, TypeIdResolver idRes, java.lang.String typePropertyName, boolean typeIdVisible, JavaType defaultImpl)
AsPropertyTypeDeserializer(JavaType bt, TypeIdResolver idRes, java.lang.String typePropertyName, boolean typeIdVisible, JavaType defaultImpl, com.fasterxml.jackson.annotation.JsonTypeInfo.As inclusion)
AsWrapperTypeDeserializer(JavaType bt, TypeIdResolver idRes, java.lang.String typePropertyName, boolean typeIdVisible, JavaType defaultImpl)
ClassNameIdResolver(JavaType baseType, TypeFactory typeFactory)
Deprecated.Since 2.10 use variant that takesPolymorphicTypeValidator
ClassNameIdResolver(JavaType baseType, TypeFactory typeFactory, PolymorphicTypeValidator ptv)
MinimalClassNameIdResolver(JavaType baseType, TypeFactory typeFactory, PolymorphicTypeValidator ptv)
TypeDeserializerBase(JavaType baseType, TypeIdResolver idRes, java.lang.String typePropertyName, boolean typeIdVisible, JavaType defaultImpl)
TypeIdResolverBase(JavaType baseType, TypeFactory typeFactory)
TypeNameIdResolver(MapperConfig<?> config, JavaType baseType, java.util.concurrent.ConcurrentHashMap<java.lang.String,java.lang.String> typeToId, java.util.HashMap<java.lang.String,JavaType> idToType)
Constructor parameters in com.fasterxml.jackson.databind.jsontype.impl with type arguments of type JavaType Constructor Description TypeNameIdResolver(MapperConfig<?> config, JavaType baseType, java.util.concurrent.ConcurrentHashMap<java.lang.String,java.lang.String> typeToId, java.util.HashMap<java.lang.String,JavaType> idToType)
-
Uses of JavaType in com.fasterxml.jackson.databind.module
Methods in com.fasterxml.jackson.databind.module that return JavaType Modifier and Type Method Description JavaType
SimpleAbstractTypeResolver. findTypeMapping(DeserializationConfig config, JavaType type)
JavaType
SimpleAbstractTypeResolver. resolveAbstractType(DeserializationConfig config, BeanDescription typeDesc)
JavaType
SimpleAbstractTypeResolver. resolveAbstractType(DeserializationConfig config, JavaType type)
Deprecated.Methods in com.fasterxml.jackson.databind.module with parameters of type JavaType Modifier and Type Method Description JsonDeserializer<?>
SimpleDeserializers. findBeanDeserializer(JavaType type, DeserializationConfig config, BeanDescription beanDesc)
KeyDeserializer
SimpleKeyDeserializers. findKeyDeserializer(JavaType type, DeserializationConfig config, BeanDescription beanDesc)
JsonSerializer<?>
SimpleSerializers. findSerializer(SerializationConfig config, JavaType type, BeanDescription beanDesc)
JavaType
SimpleAbstractTypeResolver. findTypeMapping(DeserializationConfig config, JavaType type)
JavaType
SimpleAbstractTypeResolver. resolveAbstractType(DeserializationConfig config, JavaType type)
Deprecated. -
Uses of JavaType in com.fasterxml.jackson.databind.ser
Fields in com.fasterxml.jackson.databind.ser declared as JavaType Modifier and Type Field Description protected JavaType
BeanPropertyWriter. _cfgSerializationType
Type to use for locating serializer; normally same as return type of the accessor method, but may be overridden by annotations.protected JavaType
BeanPropertyWriter. _declaredType
Type property is declared to have, either in class definition or associated annotations.protected JavaType
BeanPropertyWriter. _nonTrivialBaseType
Base type of the property, if the declared type is "non-trivial"; meaning it is either a structured type (collection, map, array), or parameterized.Methods in com.fasterxml.jackson.databind.ser that return JavaType Modifier and Type Method Description protected JavaType
PropertyBuilder. findSerializationType(Annotated a, boolean useStaticTyping, JavaType declaredType)
Method that will try to determine statically defined type of property being serialized, based on annotations (for overrides), and alternatively declared type (if static typing for serialization is enabled).abstract JavaType
ContainerSerializer. getContentType()
Accessor for finding declared (static) element type for type this serializer is used for.JavaType
BeanPropertyWriter. getSerializationType()
JavaType
BeanPropertyWriter. getType()
Methods in com.fasterxml.jackson.databind.ser with parameters of type JavaType Modifier and Type Method Description protected BeanPropertyWriter
PropertyBuilder. _constructPropertyWriter(BeanPropertyDefinition propDef, AnnotatedMember member, Annotations contextAnnotations, JavaType declaredType, JsonSerializer<?> ser, TypeSerializer typeSer, JavaType serType, boolean suppressNulls, java.lang.Object suppressableValue, java.lang.Class<?>[] includeInViews)
Overridable factory method for actual construction ofBeanPropertyWriter
; often needed if subclassingPropertyBuilder.buildWriter(com.fasterxml.jackson.databind.SerializerProvider, com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition, com.fasterxml.jackson.databind.JavaType, com.fasterxml.jackson.databind.JsonSerializer<?>, com.fasterxml.jackson.databind.jsontype.TypeSerializer, com.fasterxml.jackson.databind.jsontype.TypeSerializer, com.fasterxml.jackson.databind.introspect.AnnotatedMember, boolean)
method.protected JsonSerializer<?>
BeanSerializerFactory. _createSerializer2(SerializerProvider prov, JavaType type, BeanDescription beanDesc, boolean staticTyping)
protected com.fasterxml.jackson.annotation.JsonInclude.Value
BasicSerializerFactory. _findInclusionWithContent(SerializerProvider prov, BeanDescription beanDesc, JavaType contentType, java.lang.Class<?> configType)
Helper method used for finding inclusion definitions for structured container types likeMap
s and referential types (likeAtomicReference
).protected JsonSerializer<?>
BeanSerializerFactory. _findUnsupportedTypeSerializer(SerializerProvider ctxt, JavaType type, BeanDescription beanDesc)
void
DefaultSerializerProvider. acceptJsonFormatVisitor(JavaType javaType, JsonFormatVisitorWrapper visitor)
The method to be called byObjectMapper
andObjectWriter
to to expose the format of the given to to the given visitorvoid
SerializerCache. addAndResolveNonTypedSerializer(JavaType type, JsonSerializer<java.lang.Object> ser, SerializerProvider provider)
void
SerializerCache. addAndResolveNonTypedSerializer(java.lang.Class<?> rawType, JavaType fullType, JsonSerializer<java.lang.Object> ser, SerializerProvider provider)
Another alternative that will cover both access via raw type and matching fully resolved type, in one fell swoop.void
SerializerCache. addTypedSerializer(JavaType type, JsonSerializer<java.lang.Object> ser)
Method called if none of lookups succeeded, and caller had to construct a serializer.ContainerSerializer<?>
BasicSerializerFactory. buildCollectionSerializer(JavaType elemType, boolean staticTyping, TypeSerializer vts, JsonSerializer<java.lang.Object> valueSerializer)
protected JsonSerializer<?>
BasicSerializerFactory. buildContainerSerializer(SerializerProvider prov, JavaType type, BeanDescription beanDesc, boolean staticTyping)
protected JsonSerializer<?>
BasicSerializerFactory. buildEnumSerializer(SerializationConfig config, JavaType type, BeanDescription beanDesc)
JsonSerializer<?>
BasicSerializerFactory. buildEnumSetSerializer(JavaType enumType)
ContainerSerializer<?>
BasicSerializerFactory. buildIndexedListSerializer(JavaType elemType, boolean staticTyping, TypeSerializer vts, JsonSerializer<java.lang.Object> valueSerializer)
protected JsonSerializer<?>
BasicSerializerFactory. buildIterableSerializer(SerializationConfig config, JavaType type, BeanDescription beanDesc, boolean staticTyping, JavaType valueType)
protected JsonSerializer<?>
BasicSerializerFactory. buildIteratorSerializer(SerializationConfig config, JavaType type, BeanDescription beanDesc, boolean staticTyping, JavaType valueType)
protected JsonSerializer<?>
BasicSerializerFactory. buildMapEntrySerializer(SerializerProvider prov, JavaType type, BeanDescription beanDesc, boolean staticTyping, JavaType keyType, JavaType valueType)
protected BeanPropertyWriter
PropertyBuilder. buildWriter(SerializerProvider prov, BeanPropertyDefinition propDef, JavaType declaredType, JsonSerializer<?> ser, TypeSerializer typeSer, TypeSerializer contentTypeSer, AnnotatedMember am, boolean defaultUseStaticTyping)
protected JsonSerializer<java.lang.Object>
BeanSerializerFactory. constructBeanOrAddOnSerializer(SerializerProvider prov, JavaType type, BeanDescription beanDesc, boolean staticTyping)
Method called to construct serializer for serializing specified bean type if (but only if, as of 2.10), at least one property is found.static BeanSerializer
BeanSerializer. createDummy(JavaType forType)
Deprecated.Since 2.10static BeanSerializer
BeanSerializer. createDummy(JavaType forType, BeanSerializerBuilder builder)
Method for constructing dummy bean serializer; one that never outputs any propertiesJsonSerializer<java.lang.Object>
BasicSerializerFactory. createKeySerializer(SerializationConfig config, JavaType keyType, JsonSerializer<java.lang.Object> defaultImpl)
Deprecated.JsonSerializer<java.lang.Object>
BasicSerializerFactory. createKeySerializer(SerializerProvider ctxt, JavaType keyType, JsonSerializer<java.lang.Object> defaultImpl)
abstract JsonSerializer<java.lang.Object>
SerializerFactory. createKeySerializer(SerializationConfig config, JavaType type, JsonSerializer<java.lang.Object> defaultImpl)
Deprecated.JsonSerializer<java.lang.Object>
SerializerFactory. createKeySerializer(SerializerProvider prov, JavaType type, JsonSerializer<java.lang.Object> defaultImpl)
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<java.lang.Object>
BasicSerializerFactory. createSerializer(SerializerProvider prov, JavaType type)
JsonSerializer<java.lang.Object>
BeanSerializerFactory. createSerializer(SerializerProvider prov, JavaType origType)
Main serializer constructor method.abstract JsonSerializer<java.lang.Object>
SerializerFactory. createSerializer(SerializerProvider prov, JavaType baseType)
Method called to create (or, for immutable serializers, reuse) a serializer for given type.TypeSerializer
BasicSerializerFactory. createTypeSerializer(SerializationConfig config, JavaType baseType)
Method called to construct a type serializer for values with given declared base type.abstract TypeSerializer
SerializerFactory. createTypeSerializer(SerializationConfig config, JavaType baseType)
Method called to create a type information serializer for given base type, if one is needed.JsonSerializer<java.lang.Object>
BeanSerializerFactory. findBeanOrAddOnSerializer(SerializerProvider prov, JavaType type, BeanDescription beanDesc, boolean staticTyping)
Method that will try to construct aBeanSerializer
for given class if at least one property is found, OR, if not, one of add-on types.JsonSerializer<java.lang.Object>
BeanSerializerFactory. findBeanSerializer(SerializerProvider prov, JavaType type, BeanDescription beanDesc)
Deprecated.protected JsonSerializer<?>
BasicSerializerFactory. findOptionalStdSerializer(SerializerProvider prov, JavaType type, BeanDescription beanDesc, boolean staticTyping)
Overridable method called after checking all other types.TypeSerializer
BeanSerializerFactory. findPropertyContentTypeSerializer(JavaType containerType, SerializationConfig config, AnnotatedMember accessor)
Method called to create a type information serializer for values of given container property if one is needed.TypeSerializer
BeanSerializerFactory. findPropertyTypeSerializer(JavaType baseType, SerializationConfig config, AnnotatedMember accessor)
Method called to create a type information serializer for values of given non-container property if one is needed.protected JavaType
PropertyBuilder. findSerializationType(Annotated a, boolean useStaticTyping, JavaType declaredType)
Method that will try to determine statically defined type of property being serialized, based on annotations (for overrides), and alternatively declared type (if static typing for serialization is enabled).JsonSerializer<?>
Serializers.Base. findSerializer(SerializationConfig config, JavaType type, BeanDescription beanDesc)
JsonSerializer<?>
Serializers. findSerializer(SerializationConfig config, JavaType type, BeanDescription beanDesc)
Method called by serialization framework first time a serializer is needed for specified type, which is not of a container or reference type (for which other methods are called).protected JsonSerializer<?>
BasicSerializerFactory. findSerializerByAddonType(SerializationConfig config, JavaType javaType, BeanDescription beanDesc, boolean staticTyping)
Reflection-based serialized find method, which checks if given class implements one of recognized "add-on" interfaces.protected JsonSerializer<?>
BasicSerializerFactory. findSerializerByAnnotations(SerializerProvider prov, JavaType type, BeanDescription beanDesc)
Method called to see if one of primary per-class annotations (or related, like implementing ofJsonSerializable
) determines the serializer to use.protected JsonSerializer<?>
BasicSerializerFactory. findSerializerByLookup(JavaType type, SerializationConfig config, BeanDescription beanDesc, boolean staticTyping)
Method that will use fast lookup (and identity comparison) methods to see if we know serializer to use for given type.protected JsonSerializer<?>
BasicSerializerFactory. findSerializerByPrimaryType(SerializerProvider prov, JavaType type, BeanDescription beanDesc, 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 java.lang.Object
PropertyBuilder. getDefaultValue(JavaType type)
Deprecated.Since 2.9protected java.lang.Object
PropertyBuilder. getPropertyDefaultValue(java.lang.String name, AnnotatedMember member, JavaType type)
Deprecated.Since 2.9 since this will not allow determining difference between "no default instance" case and default being `null`.JsonSerializer<?>
BeanSerializerModifier. modifyEnumSerializer(SerializationConfig config, JavaType valueType, BeanDescription beanDesc, JsonSerializer<?> serializer)
JsonSerializer<?>
BeanSerializerModifier. modifyKeySerializer(SerializationConfig config, JavaType valueType, BeanDescription beanDesc, JsonSerializer<?> serializer)
Method called byDeserializerFactory
after it has constructed the default key serializer to use for serializingMap
keys of given type.void
DefaultSerializerProvider. serializePolymorphic(com.fasterxml.jackson.core.JsonGenerator gen, java.lang.Object value, JavaType rootType, JsonSerializer<java.lang.Object> valueSer, TypeSerializer typeSer)
Alternate serialization call used for polymorphic types, whenTypeSerializer
is already known, but the actual serializer may or may not be.void
DefaultSerializerProvider. serializeValue(com.fasterxml.jackson.core.JsonGenerator gen, java.lang.Object value, JavaType rootType)
The method to be called byObjectMapper
andObjectWriter
for serializing given value (assumed to be of specified root type, instead of runtime type of value), using serializers that this provider has access to (via caching and/or creating new serializers as need be),void
DefaultSerializerProvider. serializeValue(com.fasterxml.jackson.core.JsonGenerator gen, java.lang.Object value, JavaType rootType, JsonSerializer<java.lang.Object> ser)
The method to be called byObjectWriter
for serializing given value (assumed to be of specified root type, instead of runtime type of value), when it may know specificJsonSerializer
to use.void
BeanPropertyWriter. setNonTrivialBaseType(JavaType t)
Method called to define type to consider as "non-trivial" basetype, needed for dynamic serialization resolution for complex (usually container) typesJsonSerializer<java.lang.Object>
SerializerCache. typedValueSerializer(JavaType type)
JsonSerializer<java.lang.Object>
SerializerCache. untypedValueSerializer(JavaType type)
abstract VirtualBeanPropertyWriter
VirtualBeanPropertyWriter. withConfig(MapperConfig<?> config, AnnotatedClass declaringClass, BeanPropertyDefinition propDef, JavaType type)
Contextualization method called on a newly constructed virtual bean property.Constructors in com.fasterxml.jackson.databind.ser with parameters of type JavaType Constructor Description BeanPropertyWriter(BeanPropertyDefinition propDef, AnnotatedMember member, Annotations contextAnnotations, JavaType declaredType, JsonSerializer<?> ser, TypeSerializer typeSer, JavaType serType, boolean suppressNulls, java.lang.Object suppressableValue)
Deprecated.BeanPropertyWriter(BeanPropertyDefinition propDef, AnnotatedMember member, Annotations contextAnnotations, JavaType declaredType, JsonSerializer<?> ser, TypeSerializer typeSer, JavaType serType, boolean suppressNulls, java.lang.Object suppressableValue, java.lang.Class<?>[] includeInViews)
BeanSerializer(JavaType type, BeanSerializerBuilder builder, BeanPropertyWriter[] properties, BeanPropertyWriter[] filteredProperties)
ContainerSerializer(JavaType fullType)
VirtualBeanPropertyWriter(BeanPropertyDefinition propDef, Annotations contextAnnotations, JavaType declaredType)
Constructor used by most sub-types.VirtualBeanPropertyWriter(BeanPropertyDefinition propDef, Annotations contextAnnotations, JavaType declaredType, JsonSerializer<?> ser, TypeSerializer typeSer, JavaType serType, com.fasterxml.jackson.annotation.JsonInclude.Value inclusion)
Deprecated.VirtualBeanPropertyWriter(BeanPropertyDefinition propDef, Annotations contextAnnotations, JavaType declaredType, JsonSerializer<?> ser, TypeSerializer typeSer, JavaType serType, com.fasterxml.jackson.annotation.JsonInclude.Value inclusion, java.lang.Class<?>[] includeInViews)
Pass-through constructor that may be used by sub-classes that want full control over implementation. -
Uses of JavaType in com.fasterxml.jackson.databind.ser.impl
Fields in com.fasterxml.jackson.databind.ser.impl declared as JavaType Modifier and Type Field Description protected JavaType
MapEntrySerializer. _entryType
protected JavaType
MapEntrySerializer. _keyType
protected JavaType
UnsupportedTypeSerializer. _type
protected JavaType
MapEntrySerializer. _valueType
JavaType
ObjectIdWriter. idType
Methods in com.fasterxml.jackson.databind.ser.impl that return JavaType Modifier and Type Method Description JavaType
MapEntrySerializer. getContentType()
JavaType
StringArraySerializer. getContentType()
Methods in com.fasterxml.jackson.databind.ser.impl with parameters of type JavaType Modifier and Type Method Description protected JsonSerializer<java.lang.Object>
MapEntrySerializer. _findAndAddDynamic(PropertySerializerMap map, JavaType type, SerializerProvider provider)
void
StringArraySerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
UnknownSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
PropertySerializerMap.SerializerAndMapResult
PropertySerializerMap. addSerializer(JavaType type, JsonSerializer<java.lang.Object> serializer)
static AttributePropertyWriter
AttributePropertyWriter. construct(java.lang.String attrName, BeanPropertyDefinition propDef, Annotations contextAnnotations, JavaType declaredType)
static ObjectIdWriter
ObjectIdWriter. construct(JavaType idType, PropertyName propName, com.fasterxml.jackson.annotation.ObjectIdGenerator<?> generator, boolean alwaysAsId)
Factory method called byBeanSerializerBase
with the initial information based on standard settings for the type for which serializer is being built.PropertySerializerMap.SerializerAndMapResult
PropertySerializerMap. findAndAddPrimarySerializer(JavaType type, SerializerProvider provider, BeanProperty property)
PropertySerializerMap.SerializerAndMapResult
PropertySerializerMap. findAndAddRootValueSerializer(JavaType type, SerializerProvider provider)
PropertySerializerMap.SerializerAndMapResult
PropertySerializerMap. findAndAddSecondarySerializer(JavaType type, SerializerProvider provider, BeanProperty property)
JsonSerializer<java.lang.Object>
ReadOnlyClassToSerializerMap. typedValueSerializer(JavaType type)
JsonSerializer<java.lang.Object>
ReadOnlyClassToSerializerMap. untypedValueSerializer(JavaType type)
VirtualBeanPropertyWriter
AttributePropertyWriter. withConfig(MapperConfig<?> config, AnnotatedClass declaringClass, BeanPropertyDefinition propDef, JavaType type)
Since this method should typically not be called on this sub-type, default implementation simply throws anIllegalStateException
.Constructors in com.fasterxml.jackson.databind.ser.impl with parameters of type JavaType Constructor Description AttributePropertyWriter(java.lang.String attrName, BeanPropertyDefinition propDef, Annotations contextAnnotations, JavaType declaredType)
AttributePropertyWriter(java.lang.String attrName, BeanPropertyDefinition propDef, Annotations contextAnnotations, JavaType declaredType, com.fasterxml.jackson.annotation.JsonInclude.Value inclusion)
IndexedListSerializer(JavaType elemType, boolean staticTyping, TypeSerializer vts, JsonSerializer<java.lang.Object> valueSerializer)
IteratorSerializer(JavaType elemType, boolean staticTyping, TypeSerializer vts)
MapEntrySerializer(JavaType type, JavaType keyType, JavaType valueType, boolean staticTyping, TypeSerializer vts, BeanProperty property)
ObjectIdWriter(JavaType t, com.fasterxml.jackson.core.SerializableString propName, com.fasterxml.jackson.annotation.ObjectIdGenerator<?> gen, JsonSerializer<?> ser, boolean alwaysAsId)
UnsupportedTypeSerializer(JavaType t, java.lang.String msg)
-
Uses of JavaType in com.fasterxml.jackson.databind.ser.std
Fields in com.fasterxml.jackson.databind.ser.std declared as JavaType Modifier and Type Field Description protected JavaType
BeanSerializerBase. _beanType
protected JavaType
StdDelegatingSerializer. _delegateType
Fully resolved delegate type, with generic information if any available.protected JavaType
AsArraySerializerBase. _elementType
protected JavaType
ObjectArraySerializer. _elementType
Declared type of element entriesprotected JavaType
MapSerializer. _keyType
Declared type of keysprotected JavaType
ReferenceTypeSerializer. _referredType
Value typeprotected JavaType
JsonValueSerializer. _valueType
Declared type of the value accessed, as declared by accessor.protected JavaType
MapSerializer. _valueType
Declared type of contained valuesprotected static JavaType
MapSerializer. UNSPECIFIED_TYPE
Methods in com.fasterxml.jackson.databind.ser.std that return JavaType Modifier and Type Method Description JavaType
AsArraySerializerBase. getContentType()
JavaType
MapSerializer. getContentType()
JavaType
ObjectArraySerializer. getContentType()
JavaType
StdArraySerializers.BooleanArraySerializer. getContentType()
JavaType
StdArraySerializers.DoubleArraySerializer. getContentType()
JavaType
StdArraySerializers.FloatArraySerializer. getContentType()
JavaType
StdArraySerializers.IntArraySerializer. getContentType()
JavaType
StdArraySerializers.LongArraySerializer. getContentType()
JavaType
StdArraySerializers.ShortArraySerializer. getContentType()
JavaType
ReferenceTypeSerializer. getReferredType()
JavaType
MapProperty. getType()
Methods in com.fasterxml.jackson.databind.ser.std with parameters of type JavaType Modifier and Type Method Description protected void
DateTimeSerializerBase. _acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint, boolean asNumber)
protected boolean
JsonValueSerializer. _acceptJsonFormatVisitorForEnum(JsonFormatVisitorWrapper visitor, JavaType typeHint, java.lang.Class<?> enumType)
Overridable helper method used for special case handling of schema information for Enums.protected JsonSerializer<java.lang.Object>
AsArraySerializerBase. _findAndAddDynamic(PropertySerializerMap map, JavaType type, SerializerProvider provider)
protected JsonSerializer<java.lang.Object>
MapSerializer. _findAndAddDynamic(PropertySerializerMap map, JavaType type, SerializerProvider provider)
protected JsonSerializer<java.lang.Object>
ObjectArraySerializer. _findAndAddDynamic(PropertySerializerMap map, JavaType type, SerializerProvider provider)
protected boolean
ReferenceTypeSerializer. _useStatic(SerializerProvider provider, BeanProperty property, JavaType referredType)
void
AsArraySerializerBase. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
BeanSerializerBase. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
BooleanSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
ByteArraySerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
ByteBufferSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
ClassSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
DateTimeSerializerBase. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
EnumSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
FileSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
JsonValueSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
MapSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
NullSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
NumberSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
NumberSerializers.Base. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
ObjectArraySerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
RawSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
ReferenceTypeSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
SerializableSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
SqlTimeSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StaticListSerializerBase. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdArraySerializers.BooleanArraySerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdArraySerializers.CharArraySerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdArraySerializers.DoubleArraySerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdArraySerializers.FloatArraySerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdArraySerializers.IntArraySerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdArraySerializers.LongArraySerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdArraySerializers.ShortArraySerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdDelegatingSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdJdkSerializers.AtomicBooleanSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdJdkSerializers.AtomicIntegerSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdJdkSerializers.AtomicLongSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdKeySerializers.Dynamic. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdScalarSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
StdSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
Default implementation specifies no format.void
StringSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
TokenBufferSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
ToStringSerializerBase. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
void
UUIDSerializer. acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
static MapSerializer
MapSerializer. construct(java.lang.String[] ignoredList, JavaType mapType, boolean staticValueType, TypeSerializer vts, JsonSerializer<java.lang.Object> keySerializer, JsonSerializer<java.lang.Object> valueSerializer, java.lang.Object filterId)
Deprecated.Since 2.8 use the other overloadstatic MapSerializer
MapSerializer. construct(java.util.Set<java.lang.String> ignoredEntries, JavaType mapType, boolean staticValueType, TypeSerializer vts, JsonSerializer<java.lang.Object> keySerializer, JsonSerializer<java.lang.Object> valueSerializer, java.lang.Object filterId)
static MapSerializer
MapSerializer. construct(java.util.Set<java.lang.String> ignoredEntries, java.util.Set<java.lang.String> includedEntries, JavaType mapType, boolean staticValueType, TypeSerializer vts, JsonSerializer<java.lang.Object> keySerializer, JsonSerializer<java.lang.Object> valueSerializer, java.lang.Object filterId)
protected void
StdSerializer. visitArrayFormat(JsonFormatVisitorWrapper visitor, JavaType typeHint, JsonFormatTypes itemType)
protected void
StdSerializer. visitArrayFormat(JsonFormatVisitorWrapper visitor, JavaType typeHint, JsonSerializer<?> itemSerializer, JavaType itemType)
protected void
StdSerializer. visitFloatFormat(JsonFormatVisitorWrapper visitor, JavaType typeHint, com.fasterxml.jackson.core.JsonParser.NumberType numberType)
Helper method that calls necessary visit method(s) to indicate that the underlying JSON type is a floating-point JSON number.protected void
StdSerializer. visitIntFormat(JsonFormatVisitorWrapper visitor, JavaType typeHint, com.fasterxml.jackson.core.JsonParser.NumberType numberType)
Helper method that calls necessary visit method(s) to indicate that the underlying JSON type is JSON Integer number.protected void
StdSerializer. visitIntFormat(JsonFormatVisitorWrapper visitor, JavaType typeHint, com.fasterxml.jackson.core.JsonParser.NumberType numberType, JsonValueFormat format)
Helper method that calls necessary visit method(s) to indicate that the underlying JSON type is JSON Integer number, but that there is also a further format restriction involved.protected void
StdSerializer. visitStringFormat(JsonFormatVisitorWrapper visitor, JavaType typeHint)
Helper method that calls necessary visit method(s) to indicate that the underlying JSON type is JSON String.protected void
StdSerializer. visitStringFormat(JsonFormatVisitorWrapper visitor, JavaType typeHint, JsonValueFormat format)
Helper method that calls necessary visit method(s) to indicate that the underlying JSON type is JSON String, but that there is a more refined logical typeprotected StdDelegatingSerializer
StdDelegatingSerializer. withDelegate(Converter<java.lang.Object,?> converter, JavaType delegateType, JsonSerializer<?> delegateSerializer)
Method used for creating resolved contextual instances.Constructors in com.fasterxml.jackson.databind.ser.std with parameters of type JavaType Constructor Description AsArraySerializerBase(java.lang.Class<?> cls, JavaType elementType, boolean staticTyping, TypeSerializer vts, BeanProperty property, JsonSerializer<?> elementSerializer, java.lang.Boolean unwrapSingle)
General purpose constructor.AsArraySerializerBase(java.lang.Class<?> cls, JavaType et, boolean staticTyping, TypeSerializer vts, BeanProperty property, JsonSerializer<java.lang.Object> elementSerializer)
Deprecated.Since 2.6 Use variants that either take 'src', or do NOT pass BeanPropertyAsArraySerializerBase(java.lang.Class<?> cls, JavaType et, boolean staticTyping, TypeSerializer vts, JsonSerializer<java.lang.Object> elementSerializer)
Non-contextual, "blueprint" constructor typically called when the first instance is created, without knowledge of property it was used via.BeanSerializerBase(JavaType type, BeanSerializerBuilder builder, BeanPropertyWriter[] properties, BeanPropertyWriter[] filteredProperties)
Constructor used byBeanSerializerBuilder
to create an instanceCollectionSerializer(JavaType elemType, boolean staticTyping, TypeSerializer vts, BeanProperty property, JsonSerializer<java.lang.Object> valueSerializer)
Deprecated.since 2.6CollectionSerializer(JavaType elemType, boolean staticTyping, TypeSerializer vts, JsonSerializer<java.lang.Object> valueSerializer)
EnumSetSerializer(JavaType elemType)
IterableSerializer(JavaType elemType, boolean staticTyping, TypeSerializer vts)
MapSerializer(java.util.Set<java.lang.String> ignoredEntries, JavaType keyType, JavaType valueType, boolean valueTypeIsStatic, TypeSerializer vts, JsonSerializer<?> keySerializer, JsonSerializer<?> valueSerializer)
Deprecated.in 2.12, remove from 3.0MapSerializer(java.util.Set<java.lang.String> ignoredEntries, java.util.Set<java.lang.String> includedEntries, JavaType keyType, JavaType valueType, boolean valueTypeIsStatic, TypeSerializer vts, JsonSerializer<?> keySerializer, JsonSerializer<?> valueSerializer)
ObjectArraySerializer(JavaType elemType, boolean staticTyping, TypeSerializer vts, JsonSerializer<java.lang.Object> elementSerializer)
StdDelegatingSerializer(Converter<java.lang.Object,?> converter, JavaType delegateType, JsonSerializer<?> delegateSerializer)
StdSerializer(JavaType type)
-
Uses of JavaType in com.fasterxml.jackson.databind.type
Subclasses of JavaType in com.fasterxml.jackson.databind.type Modifier and Type Class Description class
ArrayType
Array types represent Java arrays, both primitive and object valued.class
CollectionLikeType
Type that represents things that act similar toCollection
; but may or may not be instances of that interface.class
CollectionType
Type that represents Java Collection types (Lists, Sets).class
MapLikeType
Type that represents Map-like types; things that consist of key/value pairs but that do not necessarily implementMap
, but that do not have enough introspection functionality to allow for some level of generic handling.class
MapType
Type that represents "true" Java Map types.class
PlaceholderForType
Helper type used when introspecting bindings for already resolved types, needed for specialization.class
ReferenceType
SpecializedSimpleType
for types that are referential types, that is, values that can be dereferenced to another value (or null), of different type.class
ResolvedRecursiveType
Internal placeholder type used for self-references.class
SimpleType
Simple types are defined as anything other than one of recognized container types (arrays, Collections, Maps).class
TypeBase
Fields in com.fasterxml.jackson.databind.type declared as JavaType Modifier and Type Field Description protected JavaType
PlaceholderForType. _actualType
Type assigned during wildcard resolution (which follows type structure resolution)protected JavaType
ReferenceType. _anchorType
Essential type used for type ids, for example if type id is needed for referencing type with polymorphic handling.protected JavaType
ArrayType. _componentType
Type of elements in the array.protected JavaType
CollectionLikeType. _elementType
Type of elements in collectionprotected JavaType
MapLikeType. _keyType
Type of keys of Map.protected JavaType
ReferenceType. _referencedType
protected JavaType
ResolvedRecursiveType. _referencedType
protected JavaType
TypeBase. _superClass
protected JavaType[]
TypeBase. _superInterfaces
protected JavaType
MapLikeType. _valueType
Type of values of Map.Fields in com.fasterxml.jackson.databind.type with type parameters of type JavaType Modifier and Type Field Description protected LookupCache<java.lang.Object,JavaType>
TypeFactory. _typeCache
Since type resolution can be expensive (specifically when resolving actual generic types), we will use small cache to avoid repetitive resolution of core typesMethods in com.fasterxml.jackson.databind.type that return JavaType Modifier and Type Method Description protected JavaType
TypeFactory. _applyModifiers(java.lang.reflect.Type srcType, JavaType resolvedType)
protected static JavaType
TypeBase. _bogusSuperClass(java.lang.Class<?> cls)
Internal helper method used to figure out nominal super-class for deprecated factory methods / constructors, where we are not given properly resolved supertype hierarchy.protected JavaType
TypeFactory. _constructSimple(java.lang.Class<?> raw, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
Factory method to call when no specialJavaType
is needed, no generic parameters are passed.protected JavaType
TypeFactory. _findWellKnownSimple(java.lang.Class<?> clz)
Helper method called to see if requested, non-generic-parameterized type is one of common, "well-known" types, instances of which are pre-constructed and do not need dynamic caching.protected JavaType
TypeFactory. _fromAny(ClassStack context, java.lang.reflect.Type srcType, TypeBindings bindings)
Factory method that can be used if type information is passed as Java typing returned fromgetGenericXxx
methods (usually for a return or argument type).protected JavaType
TypeFactory. _fromArrayType(ClassStack context, java.lang.reflect.GenericArrayType type, TypeBindings bindings)
protected JavaType
TypeFactory. _fromClass(ClassStack context, java.lang.Class<?> rawType, TypeBindings bindings)
protected JavaType
TypeFactory. _fromParamType(ClassStack context, java.lang.reflect.ParameterizedType ptype, TypeBindings parentBindings)
This method deals with parameterized types, that is, first class generic classes.protected JavaType
TypeFactory. _fromVariable(ClassStack context, java.lang.reflect.TypeVariable<?> var, TypeBindings bindings)
protected JavaType
TypeFactory. _fromWellKnownClass(ClassStack context, java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
Helper class used to check whether exact class for which type is being constructed is one of well-known base interfaces or classes that indicates alternateJavaType
implementation.protected JavaType
TypeFactory. _fromWellKnownInterface(ClassStack context, java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
protected JavaType
TypeFactory. _fromWildcard(ClassStack context, java.lang.reflect.WildcardType type, TypeBindings bindings)
protected JavaType
ArrayType. _narrow(java.lang.Class<?> subclass)
Deprecated.protected JavaType
CollectionLikeType. _narrow(java.lang.Class<?> subclass)
Deprecated.protected JavaType
CollectionType. _narrow(java.lang.Class<?> subclass)
Deprecated.protected JavaType
MapLikeType. _narrow(java.lang.Class<?> subclass)
Deprecated.protected JavaType
MapType. _narrow(java.lang.Class<?> subclass)
Deprecated.protected JavaType
PlaceholderForType. _narrow(java.lang.Class<?> subclass)
Deprecated.protected JavaType
ReferenceType. _narrow(java.lang.Class<?> subclass)
Deprecated.protected JavaType
ResolvedRecursiveType. _narrow(java.lang.Class<?> subclass)
Deprecated.protected JavaType
SimpleType. _narrow(java.lang.Class<?> subclass)
Deprecated.protected JavaType
TypeFactory. _newSimpleType(java.lang.Class<?> raw, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
Factory method that is to create a newSimpleType
with no checks whatsoever.protected JavaType
TypeFactory. _resolveSuperClass(ClassStack context, java.lang.Class<?> rawType, TypeBindings parentBindings)
protected JavaType[]
TypeFactory. _resolveSuperInterfaces(ClassStack context, java.lang.Class<?> rawType, TypeBindings parentBindings)
protected JavaType
TypeFactory. _unknownType()
JavaType
PlaceholderForType. actualType()
JavaType
TypeFactory. constructFromCanonical(java.lang.String canonical)
Factory method for constructing aJavaType
out of its canonical representation (seeResolvedType.toCanonical()
).JavaType
TypeFactory. constructGeneralizedType(JavaType baseType, java.lang.Class<?> superClass)
Method similar toTypeFactory.constructSpecializedType(com.fasterxml.jackson.databind.JavaType, java.lang.Class<?>)
, but that creates a less-specific type of given type.JavaType
TypeFactory. constructParametricType(java.lang.Class<?> rawType, JavaType... parameterTypes)
Factory method for constructingJavaType
that represents a parameterized type.JavaType
TypeFactory. constructParametricType(java.lang.Class<?> rawType, TypeBindings parameterTypes)
Factory method for constructingJavaType
that represents a parameterized type.JavaType
TypeFactory. constructParametricType(java.lang.Class<?> parametrized, java.lang.Class<?>... parameterClasses)
Factory method for constructingJavaType
that represents a parameterized type.JavaType
TypeFactory. constructParametrizedType(java.lang.Class<?> parametrized, java.lang.Class<?> parametersFor, JavaType... parameterTypes)
Deprecated.since 2.9 UseTypeFactory.constructParametricType(Class,JavaType...)
insteadJavaType
TypeFactory. constructParametrizedType(java.lang.Class<?> parametrized, java.lang.Class<?> parametersFor, java.lang.Class<?>... parameterClasses)
Deprecated.since 2.9 UseTypeFactory.constructParametricType(Class,Class...)
insteadJavaType
TypeFactory. constructReferenceType(java.lang.Class<?> rawType, JavaType referredType)
Method for constructing aReferenceType
instance with given type parameter (type MUST take one and only one type parameter)JavaType
TypeFactory. constructSimpleType(java.lang.Class<?> rawType, JavaType[] parameterTypes)
Method for constructing a type instance with specified parameterization.JavaType
TypeFactory. constructSimpleType(java.lang.Class<?> rawType, java.lang.Class<?> parameterTarget, JavaType[] parameterTypes)
Deprecated.Since 2.7JavaType
TypeFactory. constructSpecializedType(JavaType baseType, java.lang.Class<?> subclass)
Factory method for creating a subtype of given base type, as defined by specified subclass; but retaining generic type information if any.JavaType
TypeFactory. constructSpecializedType(JavaType baseType, java.lang.Class<?> subclass, boolean relaxedCompatibilityCheck)
Factory method for creating a subtype of given base type, as defined by specified subclass; but retaining generic type information if any.JavaType
TypeFactory. constructType(com.fasterxml.jackson.core.type.TypeReference<?> typeRef)
JavaType
TypeFactory. constructType(java.lang.reflect.Type type)
JavaType
TypeFactory. constructType(java.lang.reflect.Type type, JavaType contextType)
Deprecated.Since 2.7 (accidentally removed in 2.7.0; added back in 2.7.1)JavaType
TypeFactory. constructType(java.lang.reflect.Type type, TypeBindings bindings)
Deprecated.Since 2.12JavaType
TypeFactory. constructType(java.lang.reflect.Type type, java.lang.Class<?> contextClass)
Deprecated.Since 2.7 (accidentally removed in 2.7.0; added back in 2.7.1)JavaType
TypeBase. containedType(int index)
JavaType
TypeBindings. findBoundType(java.lang.String name)
Find type bound to specified name, if there is one; returns bound type if so, null if not.JavaType
TypeBase. findSuperType(java.lang.Class<?> rawTarget)
JavaType[]
TypeBase. findTypeParameters(java.lang.Class<?> expType)
JavaType[]
TypeFactory. findTypeParameters(JavaType type, java.lang.Class<?> expType)
Method that is to figure out actual type parameters that given class binds to generic types defined by given (generic) interface or class.JavaType[]
TypeFactory. findTypeParameters(java.lang.Class<?> clz, java.lang.Class<?> expType)
Deprecated.Since 2.7 resolve raw type first, then find type parametersJavaType[]
TypeFactory. findTypeParameters(java.lang.Class<?> clz, java.lang.Class<?> expType, TypeBindings bindings)
Deprecated.Since 2.7 resolve raw type first, then find type parametersJavaType
ReferenceType. getAnchorType()
JavaType
TypeBindings. getBoundType(int index)
JavaType
ArrayType. getContentType()
JavaType
CollectionLikeType. getContentType()
JavaType
MapLikeType. getContentType()
JavaType
ReferenceType. getContentType()
JavaType
MapLikeType. getKeyType()
JavaType
ReferenceType. getReferencedType()
JavaType
ResolvedRecursiveType. getSelfReferencedType()
JavaType
ResolvedRecursiveType. getSuperClass()
JavaType
TypeBase. getSuperClass()
abstract JavaType
TypeModifier. modifyType(JavaType type, java.lang.reflect.Type jdkType, TypeBindings context, TypeFactory typeFactory)
Method called to let modifier change constructed type definition.JavaType
TypeFactory. moreSpecificType(JavaType type1, JavaType type2)
Method that can be called to figure out more specific of two types (if they are related; that is, one implements or extends the other); or if not related, return the primary type.JavaType
TypeParser. parse(java.lang.String canonical)
protected JavaType
TypeParser. parseType(com.fasterxml.jackson.databind.type.TypeParser.MyTokenizer tokens)
JavaType
ArrayType. refine(java.lang.Class<?> contentClass, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
CollectionLikeType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
CollectionType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
MapLikeType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
MapType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
PlaceholderForType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
ReferenceType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
ResolvedRecursiveType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
SimpleType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
TypeFactory. resolveMemberType(java.lang.reflect.Type type, TypeBindings contextBindings)
Method to call when resolving types ofMember
s like Fields, Methods and Constructor parameters and there is aTypeBindings
(that describes binding of type parameters within context) to pass.protected JavaType[]
TypeBindings. typeParameterArray()
JavaType
TypeFactory. uncheckedSimpleType(java.lang.Class<?> cls)
Deprecated.Since 2.8, to indicate users should never call this method.static JavaType
TypeFactory. unknownType()
Method for constructing a marker type that indicates missing generic type information, which is handled same as simple type forjava.lang.Object
.JavaType
ArrayType. withContentType(JavaType contentType)
JavaType
CollectionLikeType. withContentType(JavaType contentType)
JavaType
CollectionType. withContentType(JavaType contentType)
JavaType
MapLikeType. withContentType(JavaType contentType)
JavaType
MapType. withContentType(JavaType contentType)
JavaType
PlaceholderForType. withContentType(JavaType contentType)
JavaType
ReferenceType. withContentType(JavaType contentType)
JavaType
ResolvedRecursiveType. withContentType(JavaType contentType)
JavaType
SimpleType. withContentType(JavaType contentType)
JavaType
PlaceholderForType. withContentTypeHandler(java.lang.Object h)
JavaType
ResolvedRecursiveType. withContentTypeHandler(java.lang.Object h)
JavaType
SimpleType. withContentTypeHandler(java.lang.Object h)
JavaType
PlaceholderForType. withContentValueHandler(java.lang.Object h)
JavaType
ResolvedRecursiveType. withContentValueHandler(java.lang.Object h)
JavaType
CollectionLikeType. withHandlersFrom(JavaType src)
JavaType
MapLikeType. withHandlersFrom(JavaType src)
JavaType
PlaceholderForType. withStaticTyping()
JavaType
ResolvedRecursiveType. withStaticTyping()
JavaType
PlaceholderForType. withTypeHandler(java.lang.Object h)
JavaType
ResolvedRecursiveType. withTypeHandler(java.lang.Object h)
JavaType
PlaceholderForType. withValueHandler(java.lang.Object h)
JavaType
ResolvedRecursiveType. withValueHandler(java.lang.Object h)
Methods in com.fasterxml.jackson.databind.type that return types with arguments of type JavaType Modifier and Type Method Description java.util.List<JavaType>
TypeBase. getInterfaces()
java.util.List<JavaType>
TypeBindings. getTypeParameters()
Accessor for getting bound types in declaration orderprotected java.util.List<JavaType>
TypeParser. parseTypes(com.fasterxml.jackson.databind.type.TypeParser.MyTokenizer tokens)
Methods in com.fasterxml.jackson.databind.type with parameters of type JavaType Modifier and Type Method Description protected JavaType
TypeFactory. _applyModifiers(java.lang.reflect.Type srcType, JavaType resolvedType)
protected JavaType
TypeFactory. _constructSimple(java.lang.Class<?> raw, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
Factory method to call when no specialJavaType
is needed, no generic parameters are passed.protected JavaType
TypeFactory. _fromWellKnownClass(ClassStack context, java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
Helper class used to check whether exact class for which type is being constructed is one of well-known base interfaces or classes that indicates alternateJavaType
implementation.protected JavaType
TypeFactory. _fromWellKnownInterface(ClassStack context, java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
protected JavaType
TypeFactory. _newSimpleType(java.lang.Class<?> raw, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
Factory method that is to create a newSimpleType
with no checks whatsoever.void
PlaceholderForType. actualType(JavaType t)
static ArrayType
ArrayType. construct(JavaType componentType, TypeBindings bindings)
static ArrayType
ArrayType. construct(JavaType componentType, TypeBindings bindings, java.lang.Object valueHandler, java.lang.Object typeHandler)
static CollectionLikeType
CollectionLikeType. construct(java.lang.Class<?> rawType, JavaType elemT)
Deprecated.Since 2.7, useCollectionLikeType.upgradeFrom(com.fasterxml.jackson.databind.JavaType, com.fasterxml.jackson.databind.JavaType)
for constructing instances, given pre-resolvedSimpleType
.static CollectionLikeType
CollectionLikeType. construct(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInts, JavaType elemT)
static CollectionType
CollectionType. construct(java.lang.Class<?> rawType, JavaType elemT)
Deprecated.Since 2.7, remove from 2.9static CollectionType
CollectionType. construct(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInts, JavaType elemT)
static MapLikeType
MapLikeType. construct(java.lang.Class<?> rawType, JavaType keyT, JavaType valueT)
Deprecated.static MapType
MapType. construct(java.lang.Class<?> rawType, JavaType keyT, JavaType valueT)
Deprecated.static MapType
MapType. construct(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInts, JavaType keyT, JavaType valueT)
static ReferenceType
ReferenceType. construct(java.lang.Class<?> cls, JavaType refType)
Deprecated.static ReferenceType
ReferenceType. construct(java.lang.Class<?> cls, TypeBindings bindings, JavaType superClass, JavaType[] superInts, JavaType refType)
ArrayType
TypeFactory. constructArrayType(JavaType elementType)
Method for constructing anArrayType
.CollectionLikeType
TypeFactory. constructCollectionLikeType(java.lang.Class<?> collectionClass, JavaType elementType)
Method for constructing aCollectionLikeType
.CollectionType
TypeFactory. constructCollectionType(java.lang.Class<? extends java.util.Collection> collectionClass, JavaType elementType)
Method for constructing aCollectionType
.JavaType
TypeFactory. constructGeneralizedType(JavaType baseType, java.lang.Class<?> superClass)
Method similar toTypeFactory.constructSpecializedType(com.fasterxml.jackson.databind.JavaType, java.lang.Class<?>)
, but that creates a less-specific type of given type.MapLikeType
TypeFactory. constructMapLikeType(java.lang.Class<?> mapClass, JavaType keyType, JavaType valueType)
Method for constructing aMapLikeType
instanceMapType
TypeFactory. constructMapType(java.lang.Class<? extends java.util.Map> mapClass, JavaType keyType, JavaType valueType)
Method for constructing aMapType
instanceJavaType
TypeFactory. constructParametricType(java.lang.Class<?> rawType, JavaType... parameterTypes)
Factory method for constructingJavaType
that represents a parameterized type.JavaType
TypeFactory. constructParametrizedType(java.lang.Class<?> parametrized, java.lang.Class<?> parametersFor, JavaType... parameterTypes)
Deprecated.since 2.9 UseTypeFactory.constructParametricType(Class,JavaType...)
insteadJavaType
TypeFactory. constructReferenceType(java.lang.Class<?> rawType, JavaType referredType)
Method for constructing aReferenceType
instance with given type parameter (type MUST take one and only one type parameter)JavaType
TypeFactory. constructSimpleType(java.lang.Class<?> rawType, JavaType[] parameterTypes)
Method for constructing a type instance with specified parameterization.JavaType
TypeFactory. constructSimpleType(java.lang.Class<?> rawType, java.lang.Class<?> parameterTarget, JavaType[] parameterTypes)
Deprecated.Since 2.7JavaType
TypeFactory. constructSpecializedType(JavaType baseType, java.lang.Class<?> subclass)
Factory method for creating a subtype of given base type, as defined by specified subclass; but retaining generic type information if any.JavaType
TypeFactory. constructSpecializedType(JavaType baseType, java.lang.Class<?> subclass, boolean relaxedCompatibilityCheck)
Factory method for creating a subtype of given base type, as defined by specified subclass; but retaining generic type information if any.JavaType
TypeFactory. constructType(java.lang.reflect.Type type, JavaType contextType)
Deprecated.Since 2.7 (accidentally removed in 2.7.0; added back in 2.7.1)static TypeBindings
TypeBindings. create(java.lang.Class<?> erasedType, JavaType typeArg1)
static TypeBindings
TypeBindings. create(java.lang.Class<?> erasedType, JavaType[] types)
static TypeBindings
TypeBindings. create(java.lang.Class<?> erasedType, JavaType typeArg1, JavaType typeArg2)
static TypeBindings
TypeBindings. createIfNeeded(java.lang.Class<?> erasedType, JavaType typeArg1)
Alternate factory method that may be called if it is possible that type does or does not require type parameters; this is mostly useful for collection- and map-like types.static TypeBindings
TypeBindings. createIfNeeded(java.lang.Class<?> erasedType, JavaType[] types)
Alternate factory method that may be called if it is possible that type does or does not require type parameters; this is mostly useful for collection- and map-like types.JavaType[]
TypeFactory. findTypeParameters(JavaType type, java.lang.Class<?> expType)
Method that is to figure out actual type parameters that given class binds to generic types defined by given (generic) interface or class.abstract JavaType
TypeModifier. modifyType(JavaType type, java.lang.reflect.Type jdkType, TypeBindings context, TypeFactory typeFactory)
Method called to let modifier change constructed type definition.JavaType
TypeFactory. moreSpecificType(JavaType type1, JavaType type2)
Method that can be called to figure out more specific of two types (if they are related; that is, one implements or extends the other); or if not related, return the primary type.JavaType
ArrayType. refine(java.lang.Class<?> contentClass, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
CollectionLikeType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
CollectionType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
MapLikeType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
MapType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
PlaceholderForType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
ReferenceType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
ResolvedRecursiveType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
JavaType
SimpleType. refine(java.lang.Class<?> rawType, TypeBindings bindings, JavaType superClass, JavaType[] superInterfaces)
void
ClassStack. resolveSelfReferences(JavaType resolved)
Method called when type that this stack frame represents is fully resolved, allowing self-references to be completed (if there are any)void
ResolvedRecursiveType. setReference(JavaType ref)
static CollectionLikeType
CollectionLikeType. upgradeFrom(JavaType baseType, JavaType elementType)
Factory method that can be used to "upgrade" a basic type into collection-like one; usually done viaTypeModifier
static MapLikeType
MapLikeType. upgradeFrom(JavaType baseType, JavaType keyT, JavaType valueT)
Factory method that can be used to "upgrade" a basic type into collection-like one; usually done viaTypeModifier
static ReferenceType
ReferenceType. upgradeFrom(JavaType baseType, JavaType refdType)
Factory method that can be used to "upgrade" a basic type into collection-like one; usually done viaTypeModifier
JavaType
ArrayType. withContentType(JavaType contentType)
JavaType
CollectionLikeType. withContentType(JavaType contentType)
JavaType
CollectionType. withContentType(JavaType contentType)
JavaType
MapLikeType. withContentType(JavaType contentType)
JavaType
MapType. withContentType(JavaType contentType)
JavaType
PlaceholderForType. withContentType(JavaType contentType)
JavaType
ReferenceType. withContentType(JavaType contentType)
JavaType
ResolvedRecursiveType. withContentType(JavaType contentType)
JavaType
SimpleType. withContentType(JavaType contentType)
JavaType
CollectionLikeType. withHandlersFrom(JavaType src)
JavaType
MapLikeType. withHandlersFrom(JavaType src)
MapLikeType
MapLikeType. withKeyType(JavaType keyType)
MapType
MapType. withKeyType(JavaType keyType)
Method parameters in com.fasterxml.jackson.databind.type with type arguments of type JavaType Modifier and Type Method Description static TypeBindings
TypeBindings. create(java.lang.Class<?> erasedType, java.util.List<JavaType> typeList)
Factory method for constructing bindings for given class using specified type parameters.TypeFactory
TypeFactory. withCache(LookupCache<java.lang.Object,JavaType> cache)
Mutant factory method that will construct newTypeFactory
with identical settings except for different cache; most likely one with bigger maximum size.TypeFactory
TypeFactory. withCache(LRUMap<java.lang.Object,JavaType> cache)
Deprecated.Since 2.12Constructors in com.fasterxml.jackson.databind.type with parameters of type JavaType Constructor Description ArrayType(JavaType componentType, TypeBindings bindings, java.lang.Object emptyInstance, java.lang.Object valueHandler, java.lang.Object typeHandler, boolean asStatic)
CollectionLikeType(TypeBase base, JavaType elemT)
CollectionLikeType(java.lang.Class<?> collT, TypeBindings bindings, JavaType superClass, JavaType[] superInts, JavaType elemT, java.lang.Object valueHandler, java.lang.Object typeHandler, boolean asStatic)
CollectionType(TypeBase base, JavaType elemT)
MapLikeType(TypeBase base, JavaType keyT, JavaType valueT)
MapLikeType(java.lang.Class<?> mapType, TypeBindings bindings, JavaType superClass, JavaType[] superInts, JavaType keyT, JavaType valueT, java.lang.Object valueHandler, java.lang.Object typeHandler, boolean asStatic)
MapType(TypeBase base, JavaType keyT, JavaType valueT)
ReferenceType(TypeBase base, JavaType refType)
Constructor used when upgrading into this type (viaReferenceType.upgradeFrom(com.fasterxml.jackson.databind.JavaType, com.fasterxml.jackson.databind.JavaType)
, the usual way forReferenceType
s to come into existence.ReferenceType(java.lang.Class<?> cls, TypeBindings bindings, JavaType superClass, JavaType[] superInts, JavaType refType, JavaType anchorType, java.lang.Object valueHandler, java.lang.Object typeHandler, boolean asStatic)
SimpleType(java.lang.Class<?> cls, TypeBindings bindings, JavaType superClass, JavaType[] superInts)
SimpleType(java.lang.Class<?> cls, TypeBindings bindings, JavaType superClass, JavaType[] superInts, int extraHash, java.lang.Object valueHandler, java.lang.Object typeHandler, boolean asStatic)
Pass-through constructor used byReferenceType
.SimpleType(java.lang.Class<?> cls, TypeBindings bindings, JavaType superClass, JavaType[] superInts, java.lang.Object valueHandler, java.lang.Object typeHandler, boolean asStatic)
TypeBase(java.lang.Class<?> raw, TypeBindings bindings, JavaType superClass, JavaType[] superInts, int hash, java.lang.Object valueHandler, java.lang.Object typeHandler, boolean asStatic)
Main constructor to use by extending classes.Constructor parameters in com.fasterxml.jackson.databind.type with type arguments of type JavaType Constructor Description TypeFactory(LookupCache<java.lang.Object,JavaType> typeCache)
TypeFactory(LookupCache<java.lang.Object,JavaType> typeCache, TypeParser p, TypeModifier[] mods, java.lang.ClassLoader classLoader)
TypeFactory(LRUMap<java.lang.Object,JavaType> typeCache)
Deprecated.Since 2.12TypeFactory(LRUMap<java.lang.Object,JavaType> typeCache, TypeParser p, TypeModifier[] mods, java.lang.ClassLoader classLoader)
Deprecated.Since 2.12 -
Uses of JavaType in com.fasterxml.jackson.databind.util
Fields in com.fasterxml.jackson.databind.util declared as JavaType Modifier and Type Field Description protected JavaType
JSONPObject. _serializationType
Optional static type to use for serialization; if null, runtime type is used.protected JavaType
JSONWrappedObject. _serializationType
Optional static type to use for serialization; if null, runtime type is used.protected JavaType
TypeKey. _type
Methods in com.fasterxml.jackson.databind.util that return JavaType Modifier and Type Method Description protected JavaType
StdConverter. _findConverterType(TypeFactory tf)
JavaType
Converter. getInputType(TypeFactory typeFactory)
Method that can be used to find out actual input (source) type; this usually can be determined from type parameters, but may need to be implemented differently from programmatically defined converters (which cannot change static type parameter bindings).JavaType
StdConverter. getInputType(TypeFactory typeFactory)
JavaType
Converter. getOutputType(TypeFactory typeFactory)
Method that can be used to find out actual output (target) type; this usually can be determined from type parameters, but may need to be implemented differently from programmatically defined converters (which cannot change static type parameter bindings).JavaType
StdConverter. getOutputType(TypeFactory typeFactory)
JavaType
SimpleBeanPropertyDefinition. getPrimaryType()
JavaType
JSONPObject. getSerializationType()
JavaType
JSONWrappedObject. getSerializationType()
JavaType
TypeKey. getType()
Methods in com.fasterxml.jackson.databind.util that return types with arguments of type JavaType Modifier and Type Method Description static java.util.List<JavaType>
ClassUtil. findSuperTypes(JavaType type, java.lang.Class<?> endBefore, boolean addClassItself)
Method that will find all sub-classes and implemented interfaces of a given class or interface.Methods in com.fasterxml.jackson.databind.util with parameters of type JavaType Modifier and Type Method Description static java.lang.String
BeanUtil. checkUnsupportedType(JavaType type)
Helper method called byBeanDeserializerFactory
andBeanSerializerFactory
to check if given unrecognized type (to be (de)serialized as general POJO) is one of "well-known" types for which there would be a datatype module; and if so, return appropriate failure message to give to caller.PropertyName
RootNameLookup. findRootName(JavaType rootType, MapperConfig<?> config)
static java.util.List<JavaType>
ClassUtil. findSuperTypes(JavaType type, java.lang.Class<?> endBefore, boolean addClassItself)
Method that will find all sub-classes and implemented interfaces of a given class or interface.static java.lang.Object
BeanUtil. getDefaultValue(JavaType type)
Accessor used to find out "default value" to use for comparing values to serialize, to determine whether to exclude value from serialization with inclusion type ofJsonInclude.Include.NON_DEFAULT
.static java.lang.String
ClassUtil. getTypeDescription(JavaType fullType)
Helper method to create and return "backticked" description of given resolved type (or,"null"
ifnull
passed), similar to return vaue ofClassUtil.getClassDescription(Object)
.static java.lang.Class<?>
ClassUtil. rawClass(JavaType t)
void
TypeKey. resetTyped(JavaType type)
void
TypeKey. resetUntyped(JavaType type)
static int
TypeKey. typedHash(JavaType type)
static int
TypeKey. untypedHash(JavaType type)
Constructors in com.fasterxml.jackson.databind.util with parameters of type JavaType Constructor Description JSONPObject(java.lang.String function, java.lang.Object value, JavaType asType)
JSONWrappedObject(java.lang.String prefix, java.lang.String suffix, java.lang.Object value, JavaType asType)
Constructor that should be used when specific serialization type to use is important, and needs to be passed instead of just using runtime (type-erased) type of the value.TypeKey(JavaType key, boolean typed)
-