org.jtransfo
Interface ConvertInterceptor
public interface ConvertInterceptor
Interceptor which allows additional work to be done when jTransfo converts between objects.
The functions like around advice in AOP.
The interceptor should be re-entrant. A singleton may be used for all convert invocations.
The interceptors can for example be used to handle validation.
convert
<T> T convert(Object source,
T target,
boolean isTargetTo,
ConvertSourceTarget next,
String... tags)
- Interceptor for
JTransfo.convert(Object, Object, String...).
- Type Parameters:
T - type of object to convert to- Parameters:
source - source to convert fromtarget - object to convert toisTargetTo - is the target class the transfer object?next - next in the interceptor chain, handles the actual converttags - tags for the conversion
- Returns:
- target object after convert
Copyright © 2013. All rights reserved.