Class Jackson2Metadata
java.lang.Object
org.springframework.data.rest.webmvc.json.Jackson2Metadata
- All Implemented Interfaces:
Iterable<com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition>
@Deprecated(since="5.0",
forRemoval=true)
public class Jackson2Metadata
extends Object
implements Iterable<com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition>
Deprecated, for removal: This API element is subject to removal in a future version.
Value object to abstract Jackson based bean metadata of a given type.
- Author:
- Oliver Gierke, Greg Turnquist
-
Constructor Summary
ConstructorsConstructorDescriptionJackson2Metadata(com.fasterxml.jackson.databind.ObjectMapper mapper, Class<?> type) Deprecated, for removal: This API element is subject to removal in a future version.Creates a newJackson2Metadatainstance for the givenObjectMapperand type. -
Method Summary
Modifier and TypeMethodDescription@Nullable com.fasterxml.jackson.databind.introspect.BeanPropertyDefinitiongetDefinitionFor(PersistentProperty<?> property) Deprecated, for removal: This API element is subject to removal in a future version.Returns theBeanPropertyDefinitionfor the givenPersistentProperty.getFallbackDescription(ResourceMetadata ownerMetadata, com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition definition) Deprecated, for removal: This API element is subject to removal in a future version.Returns the fallbackResourceDescriptionto be used for the givenBeanPropertyDefinition.@Nullable com.fasterxml.jackson.databind.JsonSerializer<?> getTypeSerializer(Class<?> type) Deprecated, for removal: This API element is subject to removal in a future version.Returns theJsonSerializerfor the given type, or null if none available.booleanisExported(PersistentProperty<?> property) Deprecated, for removal: This API element is subject to removal in a future version.Check if a given property for a type is available to be exported, i.e. serialized via Jackson.booleanisReadOnly(PersistentProperty<?> property) Deprecated, for removal: This API element is subject to removal in a future version.Returns whether the givenPersistentPropertyis considered read-only by Jackson.booleanDeprecated, for removal: This API element is subject to removal in a future version.Returns whether the backing type is considered a Jackson value type.Iterator<com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition> iterator()Deprecated, for removal: This API element is subject to removal in a future version.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Iterable
forEach, spliterator
-
Constructor Details
-
Jackson2Metadata
Deprecated, for removal: This API element is subject to removal in a future version.Creates a newJackson2Metadatainstance for the givenObjectMapperand type.- Parameters:
mapper- must not be null.type- must not be null.
-
-
Method Details
-
getDefinitionFor
public @Nullable com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition getDefinitionFor(PersistentProperty<?> property) Deprecated, for removal: This API element is subject to removal in a future version.Returns theBeanPropertyDefinitionfor the givenPersistentProperty.- Parameters:
property- must not be null.- Returns:
- can be null in case there's no Jackson property to be exposed for the given
PersistentProperty.
-
getFallbackDescription
public ResourceDescription getFallbackDescription(ResourceMetadata ownerMetadata, com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition definition) Deprecated, for removal: This API element is subject to removal in a future version.Returns the fallbackResourceDescriptionto be used for the givenBeanPropertyDefinition.- Parameters:
ownerMetadata- must not be null.definition- must not be null.- Returns:
-
isExported
Deprecated, for removal: This API element is subject to removal in a future version.Check if a given property for a type is available to be exported, i.e. serialized via Jackson.- Parameters:
property- must not be null.- Returns:
-
isValueType
public boolean isValueType()Deprecated, for removal: This API element is subject to removal in a future version.Returns whether the backing type is considered a Jackson value type.- Returns:
- the isValue
-
isReadOnly
Deprecated, for removal: This API element is subject to removal in a future version.Returns whether the givenPersistentPropertyis considered read-only by Jackson.- Parameters:
property- must not be null.- Returns:
-
getTypeSerializer
Deprecated, for removal: This API element is subject to removal in a future version.Returns theJsonSerializerfor the given type, or null if none available.- Parameters:
type- must not be null.- Returns:
-
iterator
-