FieldMapper<S,T>, Mapper<S,T>public class ContextualMapper<S,T> extends Object implements Mapper<S,T>
| Constructor | Description |
|---|---|
ContextualMapper(Mapper<S,T> delegate,
MappingContextFactory<S> mappingContextFactory) |
| Modifier and Type | Method | Description |
|---|---|---|
T |
map(S source) |
map source object to a new newInstance of T
|
T |
map(S source,
MappingContext<? super S> context) |
|
void |
mapTo(S source,
T target,
MappingContext<? super S> context) |
map source object to target object.
|
MappingContext<S> |
newMappingContext() |
|
String |
toString() |
public ContextualMapper(Mapper<S,T> delegate, MappingContextFactory<S> mappingContextFactory)
public MappingContext<S> newMappingContext()
public T map(S source) throws MappingException
Mappermap in interface Mapper<S,T>source - object to map fromMappingException - if an exception occurspublic T map(S source, MappingContext<? super S> context) throws MappingException
map in interface Mapper<S,T>MappingExceptionpublic void mapTo(S source, T target, MappingContext<? super S> context) throws Exception
FieldMappermapTo in interface FieldMapper<S,T>source - object to map fromtarget - object to map tocontext - the mapping contextException - if an exception occursCopyright © 2018. All rights reserved.