Package org.apache.camel.converter.dozer
Class DozerTypeConverterLoader
- java.lang.Object
-
- org.apache.camel.support.service.BaseService
-
- org.apache.camel.support.service.ServiceSupport
-
- org.apache.camel.converter.dozer.DozerTypeConverterLoader
-
- All Implemented Interfaces:
AutoCloseable,org.apache.camel.CamelContextAware,org.apache.camel.Service,org.apache.camel.ShutdownableService,org.apache.camel.StatefulService,org.apache.camel.SuspendableService
@Deprecated public class DozerTypeConverterLoader extends org.apache.camel.support.service.ServiceSupport implements org.apache.camel.CamelContextAware
Deprecated.DozerTypeConverterLoaderprovides the mechanism for registering a DozerMapperasTypeConverterfor aCamelContext. While a mapper can be explicitly supplied as a parameter theCamelContext's registry will also be searched forMapperinstances. ADozerTypeConverteris created to wrap eachMapperinstance and the mapper is queried for the types it converts. The queried types are used to register theTypeConverterwith the context via itsTypeConverterRegistry.
-
-
Constructor Summary
Constructors Constructor Description DozerTypeConverterLoader()Deprecated.Creates aDozerTypeConverterperforming noTypeConverterregistration.DozerTypeConverterLoader(org.apache.camel.CamelContext camelContext)Deprecated.Creates aDozerTypeConverterthat will search the givenCamelContextfor instances ofMapper.DozerTypeConverterLoader(org.apache.camel.CamelContext camelContext, DozerBeanMapperConfiguration configuration)Deprecated.Creates aDozerTypeConverterusing the givenDozerBeanMapperConfigurationconfiguration.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected voidaddDozerTypeConverter(org.apache.camel.spi.TypeConverterRegistry registry, DozerTypeConverter converter, String dozerId, Class<?> to, Class<?> from)Deprecated.protected voiddoStart()Deprecated.protected voiddoStop()Deprecated.org.apache.camel.CamelContextgetCamelContext()Deprecated.com.github.dozermapper.core.MappergetMapper()Deprecated.voidinit(org.apache.camel.CamelContext camelContext, com.github.dozermapper.core.Mapper mapper)Deprecated.Doses the actual querying and registration ofDozerTypeConverters with theCamelContext.protected Map<String,DozerBeanMapperConfiguration>lookupDozerBeanMapperConfigurations()Deprecated.Lookup the dozerDozerBeanMapperConfigurationto be used.protected Map<String,com.github.dozermapper.core.Mapper>lookupDozerBeanMappers()Deprecated.Lookup the dozerMapperto be used.protected voidregisterClassMaps(org.apache.camel.spi.TypeConverterRegistry registry, String dozerId, com.github.dozermapper.core.Mapper dozer, List<com.github.dozermapper.core.metadata.ClassMappingMetadata> all)Deprecated.voidsetCamelContext(org.apache.camel.CamelContext camelContext)Deprecated.Sets theCamelContextand also initializes this loader.voidsetMapper(com.github.dozermapper.core.Mapper mapper)Deprecated.-
Methods inherited from class org.apache.camel.support.service.BaseService
build, doBuild, doFail, doInit, doLifecycleChange, doResume, doShutdown, doSuspend, fail, getStatus, init, isBuild, isInit, isNew, isRunAllowed, isShutdown, isStarted, isStarting, isStartingOrStarted, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, isSuspendingOrSuspended, resume, shutdown, start, stop, suspend
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
-
-
Constructor Detail
-
DozerTypeConverterLoader
public DozerTypeConverterLoader()
Deprecated.Creates aDozerTypeConverterperforming noTypeConverterregistration.
-
DozerTypeConverterLoader
public DozerTypeConverterLoader(org.apache.camel.CamelContext camelContext)
Deprecated.Creates aDozerTypeConverterthat will search the givenCamelContextfor instances ofMapper. Each discovered instance will be wrapped as aDozerTypeConverterand register as aTypeConverterwith the context- Parameters:
camelContext- the context to register theDozerTypeConverterin
-
DozerTypeConverterLoader
public DozerTypeConverterLoader(org.apache.camel.CamelContext camelContext, DozerBeanMapperConfiguration configuration)Deprecated.Creates aDozerTypeConverterusing the givenDozerBeanMapperConfigurationconfiguration.- Parameters:
camelContext- the context to register theDozerTypeConverterinconfiguration- dozer mapping bean configuration.
-
-
Method Detail
-
init
public void init(org.apache.camel.CamelContext camelContext, com.github.dozermapper.core.Mapper mapper)Deprecated.Doses the actual querying and registration ofDozerTypeConverters with theCamelContext.- Parameters:
camelContext- the context to register theDozerTypeConverterinmapper- the DozerMapperBean to be wrapped as a type converter.
-
lookupDozerBeanMappers
protected Map<String,com.github.dozermapper.core.Mapper> lookupDozerBeanMappers()
Deprecated.Lookup the dozerMapperto be used.
-
lookupDozerBeanMapperConfigurations
protected Map<String,DozerBeanMapperConfiguration> lookupDozerBeanMapperConfigurations()
Deprecated.Lookup the dozerDozerBeanMapperConfigurationto be used.
-
registerClassMaps
protected void registerClassMaps(org.apache.camel.spi.TypeConverterRegistry registry, String dozerId, com.github.dozermapper.core.Mapper dozer, List<com.github.dozermapper.core.metadata.ClassMappingMetadata> all)Deprecated.
-
addDozerTypeConverter
protected void addDozerTypeConverter(org.apache.camel.spi.TypeConverterRegistry registry, DozerTypeConverter converter, String dozerId, Class<?> to, Class<?> from)Deprecated.
-
getCamelContext
public org.apache.camel.CamelContext getCamelContext()
Deprecated.- Specified by:
getCamelContextin interfaceorg.apache.camel.CamelContextAware
-
setCamelContext
public void setCamelContext(org.apache.camel.CamelContext camelContext)
Deprecated.Sets theCamelContextand also initializes this loader. The reason whyinit(org.apache.camel.CamelContext, com.github.dozermapper.core.Mapper)is also called is because making using Dozer in Spring XML files easier, as no need to use the init-method attribute.- Specified by:
setCamelContextin interfaceorg.apache.camel.CamelContextAware- Parameters:
camelContext- the CamelContext
-
getMapper
public com.github.dozermapper.core.Mapper getMapper()
Deprecated.
-
setMapper
public void setMapper(com.github.dozermapper.core.Mapper mapper)
Deprecated.
-
doStart
protected void doStart() throws ExceptionDeprecated.- Overrides:
doStartin classorg.apache.camel.support.service.BaseService- Throws:
Exception
-
-