public class HeaderEnricher extends IntegrationObjectSupport implements Transformer, BeanNameAware, InitializingBean
| Constructor and Description |
|---|
HeaderEnricher() |
HeaderEnricher(Map<String,? extends HeaderValueMessageProcessor<?>> headersToAdd)
Create a HeaderEnricher with the given map of headers.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getComponentType()
Subclasses may implement this method to provide component type information.
|
void |
onInit()
Subclasses may implement this for initialization logic.
|
void |
setDefaultOverwrite(boolean defaultOverwrite) |
<T> void |
setMessageProcessor(MessageProcessor<T> messageProcessor) |
void |
setShouldSkipNulls(boolean shouldSkipNulls)
Specify whether
null values, such as might be returned from
an expression evaluation, should be skipped. |
Message<?> |
transform(Message<?> message) |
afterPropertiesSet, extractTypeIfPossible, getApplicationContext, getApplicationContextId, getBeanFactory, getComponentName, getConversionService, getIntegrationProperties, getIntegrationProperty, getMessageBuilderFactory, getTaskScheduler, setApplicationContext, setBeanFactory, setBeanName, setComponentName, setConversionService, setMessageBuilderFactory, setTaskScheduler, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitsetBeanNameafterPropertiesSetpublic HeaderEnricher()
public HeaderEnricher(Map<String,? extends HeaderValueMessageProcessor<?>> headersToAdd)
headersToAdd - The headers to add.public <T> void setMessageProcessor(MessageProcessor<T> messageProcessor)
public void setDefaultOverwrite(boolean defaultOverwrite)
public void setShouldSkipNulls(boolean shouldSkipNulls)
null values, such as might be returned from
an expression evaluation, should be skipped. The default value is
true. Set this to false if a
null value should trigger removal of the
corresponding header instead.shouldSkipNulls - true when null values should be skipped.public String getComponentType()
IntegrationObjectSupportgetComponentType in interface NamedComponentgetComponentType in class IntegrationObjectSupportpublic Message<?> transform(Message<?> message)
transform in interface GenericTransformer<Message<?>,Message<?>>transform in interface Transformerpublic void onInit()
throws Exception
IntegrationObjectSupportonInit in class IntegrationObjectSupportException - Any exception.