com.hammurapi.convert
Class ContextConverterFactory
java.lang.Object
com.hammurapi.convert.ContextConverterFactory
public class ContextConverterFactory
- extends Object
Creates converters from Context and MutableContext to interfaces which have only setters and getters (beans)
- Author:
- Pavel
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ContextConverterFactory
public ContextConverterFactory()
getConverter
public static <S,T> ConverterClosure<S,T> getConverter(Class<S> sourceClass,
Class<T> targetInterface)
- Parameters:
sourceClass - targetInterface -
- Returns:
- Converter which can "duck-type" instance of source class to target interface or null if conversion is not possible.
Methods are mapped as follows: return types shall be compatible, arguments shall be compatible, exception declarations are ignored.