ma.glasnost.orika.constructor
Class SimpleConstructorResolverStrategy
java.lang.Object
ma.glasnost.orika.constructor.SimpleConstructorResolverStrategy
- All Implemented Interfaces:
- ConstructorResolverStrategy
public class SimpleConstructorResolverStrategy
- extends Object
- implements ConstructorResolverStrategy
SimpleConstructorResolverStrategy attempts to resolve the appropriate constructor
to use in a field mapping by the following algorithm:
- If an explicit constructor has been defined (based on parameter names), then use it
- Attempt to find a constructor which has parameter names matching all of the mapped
property names of the destination class
- Return the first constructor in the list
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SimpleConstructorResolverStrategy
public SimpleConstructorResolverStrategy()
resolve
public <T,A,B> ConstructorResolverStrategy.ConstructorMapping<T> resolve(ClassMap<A,B> classMap,
Type<T> sourceType)
- Specified by:
resolve in interface ConstructorResolverStrategy
Copyright © 2013 Glasnost. All Rights Reserved.