Class ObjectToStringTransformer
java.lang.Object
org.springframework.integration.context.IntegrationObjectSupport
org.springframework.integration.transformer.AbstractTransformer
org.springframework.integration.transformer.AbstractPayloadTransformer<Object,String>
 
org.springframework.integration.transformer.ObjectToStringTransformer
- All Implemented Interfaces:
- Aware,- BeanFactoryAware,- BeanNameAware,- InitializingBean,- ApplicationContextAware,- ExpressionCapable,- GenericTransformer<Message<?>,,- Message<?>> - NamedComponent,- Transformer
A simple transformer that creates an outbound payload by invoking the
 inbound payload Object's 
toString() method. Unless the
 payload is a byte[] or char[]. If the payload
 is a byte[], it will be transformed to a String containing the
 array's contents, using the charset
 which, by default, is "UTF-8". If the payload is a char[], it will be
 transformed to a String object with the array's contents.- Since:
- 1.0.1
- Author:
- Mark Fisher, Andrew Cowlin, Gary Russell
- 
Field SummaryFields inherited from class org.springframework.integration.context.IntegrationObjectSupportEXPRESSION_PARSER, logger
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionSubclasses may implement this method to provide component type information.protected StringtransformPayload(Object payload) Methods inherited from class org.springframework.integration.transformer.AbstractPayloadTransformerdoTransformMethods inherited from class org.springframework.integration.transformer.AbstractTransformertransformMethods inherited from class org.springframework.integration.context.IntegrationObjectSupportafterPropertiesSet, extractTypeIfPossible, generateId, getApplicationContext, getApplicationContextId, getBeanDescription, getBeanFactory, getBeanName, getChannelResolver, getComponentName, getConversionService, getExpression, getIntegrationProperties, getIntegrationProperty, getMessageBuilderFactory, getTaskScheduler, isInitialized, onInit, setApplicationContext, setBeanFactory, setBeanName, setChannelResolver, setComponentName, setConversionService, setMessageBuilderFactory, setPrimaryExpression, setTaskScheduler, toString
- 
Constructor Details- 
ObjectToStringTransformerpublic ObjectToStringTransformer()
- 
ObjectToStringTransformer
 
- 
- 
Method Details- 
getComponentTypeDescription copied from class:IntegrationObjectSupportSubclasses may implement this method to provide component type information.- Specified by:
- getComponentTypein interface- NamedComponent
- Overrides:
- getComponentTypein class- IntegrationObjectSupport
 
- 
transformPayload- Specified by:
- transformPayloadin class- AbstractPayloadTransformer<Object,- String> 
 
 
-