public class PersistentEntityToJsonSchemaConverter extends Object implements ConditionalGenericConverter
JsonSchema
instances for PersistentEntity
s.GenericConverter.ConvertiblePair
Constructor and Description |
---|
PersistentEntityToJsonSchemaConverter(PersistentEntities entities,
ResourceMappings mappings,
MessageSourceAccessor accessor,
com.fasterxml.jackson.databind.ObjectMapper objectMapper,
RepositoryRestConfiguration configuration)
Creates a new
PersistentEntityToJsonSchemaConverter for the given PersistentEntities and
ResourceMappings . |
Modifier and Type | Method and Description |
---|---|
JsonSchema |
convert(Class<?> domainType)
Converts the given type into a
JsonSchema instance. |
JsonSchema |
convert(Object source,
TypeDescriptor sourceType,
TypeDescriptor targetType) |
Set<GenericConverter.ConvertiblePair> |
getConvertibleTypes() |
boolean |
matches(TypeDescriptor sourceType,
TypeDescriptor targetType) |
public PersistentEntityToJsonSchemaConverter(PersistentEntities entities, ResourceMappings mappings, MessageSourceAccessor accessor, com.fasterxml.jackson.databind.ObjectMapper objectMapper, RepositoryRestConfiguration configuration)
PersistentEntityToJsonSchemaConverter
for the given PersistentEntities
and
ResourceMappings
.entities
- must not be null.mappings
- must not be null.accessor
- must not be null.objectMapper
- must not be null.configuration
- must not be null.public boolean matches(TypeDescriptor sourceType, TypeDescriptor targetType)
matches
in interface ConditionalConverter
public Set<GenericConverter.ConvertiblePair> getConvertibleTypes()
getConvertibleTypes
in interface GenericConverter
public JsonSchema convert(Class<?> domainType)
JsonSchema
instance.domainType
- must not be null.public JsonSchema convert(Object source, TypeDescriptor sourceType, TypeDescriptor targetType)
convert
in interface GenericConverter
Copyright © 2011-2015–2016 Pivotal Software, Inc.. All rights reserved.