public class BeanViewDescriptorProvider extends BaseBeanDescriptorProvider
BeanView
mechanism. This class is mainly intended for internal use. It can be directly used if needed to
get a BeanDescriptor instance for a BeanView (for example if you want to deserialize into an
existing object and apply a BeanView). Extending BeanViewDescriptorProvider should be avoided.Modifier and Type | Class and Description |
---|---|
static class |
BeanViewDescriptorProvider.BeanViewMutatorAccessorResolver |
static class |
BeanViewDescriptorProvider.BeanViewPropertyFactory |
AbstractBeanDescriptorProvider.ContextualConverterFactory, AbstractBeanDescriptorProvider.ContextualFactoryDecorator
BeanDescriptorProvider.CompositeBeanDescriptorProvider
favorEmptyCreators, mutatorAccessorResolver, nameResolver, useFields, useGettersAndSetters
Constructor and Description |
---|
BeanViewDescriptorProvider(AbstractBeanDescriptorProvider.ContextualConverterFactory ctxConverterFactory,
Map<Class<?>,BeanView<?>> views,
BeanPropertyFactory propertyFactory,
BeanMutatorAccessorResolver mutatorAccessorResolver,
PropertyNameResolver nameResolver) |
Modifier and Type | Method and Description |
---|---|
<T> BeanDescriptor<T> |
provide(Class<T> ofClass,
Type ofType,
Genson genson)
Provides a BeanDescriptor that can serialize/deserialize "ofClass" type, based on "type"
argument.
|
List<BeanCreator> |
provideBeanCreators(Type ofType,
Genson genson)
Provides a list of
BeanCreator for type ofType. |
_mostSpecificPropertyDeclaringClass, _throwCouldCreateBeanDescriptor, checkAndMerge, checkAndMergeAccessors, checkAndMergeMutators, mergeAccessorsWithCreatorProperties, mergeMutatorsWithCreatorProperties, provideBeanPropertyAccessors, provideBeanPropertyMutators, provideConstructorCreators, provideFieldAccessors, provideFieldMutators, provideMethodAccessors, provideMethodCreators, provideMethodMutators, update
create, provide
public BeanViewDescriptorProvider(AbstractBeanDescriptorProvider.ContextualConverterFactory ctxConverterFactory, Map<Class<?>,BeanView<?>> views, BeanPropertyFactory propertyFactory, BeanMutatorAccessorResolver mutatorAccessorResolver, PropertyNameResolver nameResolver)
public <T> BeanDescriptor<T> provide(Class<T> ofClass, Type ofType, Genson genson)
BeanDescriptorProvider
provide
in interface BeanDescriptorProvider
provide
in class AbstractBeanDescriptorProvider
ofClass
- is the Class for which we need a BeanDescriptor that will be able to
serialize/deserialize objects of that type;ofType
- to use to build this descriptor (use its declared methods, fields, etc).genson
- is the current Genson instance.public List<BeanCreator> provideBeanCreators(Type ofType, Genson genson)
AbstractBeanDescriptorProvider
BeanCreator
for type ofType.provideBeanCreators
in class BaseBeanDescriptorProvider
Copyright © 2019. All rights reserved.