public class CollectionConverter<T> extends Object implements BeanConverter
Constructor and Description |
---|
CollectionConverter(CollectionHandler<T> collectionHandler) |
Modifier and Type | Method and Description |
---|---|
T |
convert(BeanMapper beanMapper,
Object source,
Class<?> targetClass,
BeanFieldMatch beanFieldMatch)
Converts the source instance into the desired target type.
|
boolean |
match(Class<?> sourceClass,
Class<?> targetClass)
Determines if the conversion of our source type to a
target type is supported by this converter.
|
public CollectionConverter(CollectionHandler<T> collectionHandler)
public T convert(BeanMapper beanMapper, Object source, Class<?> targetClass, BeanFieldMatch beanFieldMatch)
BeanConverter
convert
in interface BeanConverter
beanMapper
- the instance of BeanMapper to use for further mappingssource
- the source instancetargetClass
- the desired target typebeanFieldMatch
- information on the field pair (source / target)public boolean match(Class<?> sourceClass, Class<?> targetClass)
BeanConverter
match
in interface BeanConverter
sourceClass
- the source classtargetClass
- the target classtrue
if the conversion is supported, else false
Copyright © 2015–2017 42 BV. All rights reserved.