Spring Integration

org.springframework.integration.aop
Class SimpleExpressionSource

java.lang.Object
  extended by org.springframework.integration.aop.AbstractExpressionSource
      extended by org.springframework.integration.aop.SimpleExpressionSource

public class SimpleExpressionSource
extends AbstractExpressionSource

Simple implementation of ExpressionSource that allows for configuration of a single channel name, payload expression, and array of header key=value expressions.

Since:
2.0
Author:
Mark Fisher

Field Summary
static String DEFAULT_ARGUMENT_MAP_VARIABLE_NAME
           
static String DEFAULT_EXCEPTION_VARIABLE_NAME
           
static String DEFAULT_METHOD_NAME_VARIABLE_NAME
           
static String DEFAULT_RETURN_VALUE_VARIABLE_NAME
           
 
Constructor Summary
SimpleExpressionSource()
           
 
Method Summary
 String[] getArgumentVariableNames(Method method)
          Returns the variable names to be associated with the intercepted method invocation's argument array.
 String getChannelName(Method method)
          Returns the channel name to which Messages should be published for this particular method invocation.
 Map<String,String> getHeaderExpressions(Method method)
          Returns the map of expression strings to be evaluated for any headers that should be set on the published Message.
 String getPayloadExpression(Method method)
          Returns the expression string to be evaluated for creating the Message payload.
 void setChannelName(String channelName)
           
 void setHeaderExpressions(Map<String,String> headerExpressions)
           
 void setPayloadExpression(String payloadExpression)
           
 
Methods inherited from class org.springframework.integration.aop.AbstractExpressionSource
discoverMethodParameterNames, getArgumentMapVariableName, getExceptionVariableName, getMethodNameVariableName, getReturnValueVariableName, setArgumentMapVariableName, setExceptionVariableName, setMethodNameVariableName, setReturnValueVariableName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_METHOD_NAME_VARIABLE_NAME

public static final String DEFAULT_METHOD_NAME_VARIABLE_NAME
See Also:
Constant Field Values

DEFAULT_ARGUMENT_MAP_VARIABLE_NAME

public static final String DEFAULT_ARGUMENT_MAP_VARIABLE_NAME
See Also:
Constant Field Values

DEFAULT_RETURN_VALUE_VARIABLE_NAME

public static final String DEFAULT_RETURN_VALUE_VARIABLE_NAME
See Also:
Constant Field Values

DEFAULT_EXCEPTION_VARIABLE_NAME

public static final String DEFAULT_EXCEPTION_VARIABLE_NAME
See Also:
Constant Field Values
Constructor Detail

SimpleExpressionSource

public SimpleExpressionSource()
Method Detail

setChannelName

public void setChannelName(String channelName)

getChannelName

public String getChannelName(Method method)
Returns the channel name to which Messages should be published for this particular method invocation.

Specified by:
getChannelName in class AbstractExpressionSource

setPayloadExpression

public void setPayloadExpression(String payloadExpression)

getPayloadExpression

public String getPayloadExpression(Method method)
Returns the expression string to be evaluated for creating the Message payload.

Specified by:
getPayloadExpression in class AbstractExpressionSource

setHeaderExpressions

public void setHeaderExpressions(Map<String,String> headerExpressions)

getHeaderExpressions

public Map<String,String> getHeaderExpressions(Method method)
Returns the map of expression strings to be evaluated for any headers that should be set on the published Message. The keys in the Map are header names, the values are the expression strings.

Specified by:
getHeaderExpressions in class AbstractExpressionSource

getArgumentVariableNames

public String[] getArgumentVariableNames(Method method)
Returns the variable names to be associated with the intercepted method invocation's argument array.

Specified by:
getArgumentVariableNames in class AbstractExpressionSource

Spring Integration

Copyright © 2010. All Rights Reserved.