org.polyforms.di.converter
Class SpringConverter
java.lang.Object
org.polyforms.di.converter.SpringConverter
- All Implemented Interfaces:
- org.modelmapper.Converter<Object,Object>, org.modelmapper.spi.ConditionalConverter<Object,Object>
@Named
public class SpringConverter
- extends Object
- implements org.modelmapper.spi.ConditionalConverter<Object,Object>
Adapter of Spring ConversionService for ModelMapper Converter.
- Since:
- 1.0
- Author:
- Kuisong Tong
| Nested classes/interfaces inherited from interface org.modelmapper.spi.ConditionalConverter |
org.modelmapper.spi.ConditionalConverter.MatchResult |
|
Constructor Summary |
SpringConverter(javax.inject.Provider<org.springframework.core.convert.ConversionService> conversionServiceProvider)
Create an instance with Spring ConversionService. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SpringConverter
@Inject
public SpringConverter(javax.inject.Provider<org.springframework.core.convert.ConversionService> conversionServiceProvider)
- Create an instance with Spring
ConversionService.
convert
public Object convert(org.modelmapper.spi.MappingContext<Object,Object> context)
-
- Specified by:
convert in interface org.modelmapper.Converter<Object,Object>
match
public org.modelmapper.spi.ConditionalConverter.MatchResult match(Class<?> sourceType,
Class<?> destinationType)
-
- Specified by:
match in interface org.modelmapper.spi.ConditionalConverter<Object,Object>
Copyright © 2010-2011 Polyforms Framework. All Rights Reserved.