Package org.apache.camel.language.simple
Class SimpleExpressionBuilder
java.lang.Object
org.apache.camel.language.simple.SimpleExpressionBuilder
Expression builder used by the simple language.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classExpression adapter for OGNL expression from Message Header or Exchange property -
Method Summary
Modifier and TypeMethodDescriptionstatic org.apache.camel.ExpressionbodyOgnlExpression(String ognl) Returns the expression for the exchanges inbound message body invoking methods defined in a simple OGNL notationstatic org.apache.camel.ExpressionbodyOgnlExpression(String name, String ognl) Returns the expression for the exchanges inbound message body converted to the given type and invoking methods on the converted body defined in a simple OGNL notationstatic org.apache.camel.ExpressioncacheExpression(org.apache.camel.Expression expression) Returns an expression that caches the evaluation of another expression and returns the cached value, to avoid re-evaluating the expression.static org.apache.camel.ExpressionReturns the expression for the exchanges camelContext invoking methods defined in a simple OGNL notationstatic org.apache.camel.ExpressioncollateExpression(String expression, int group) Returns an iterator to collate (iterate) the given expressionstatic org.apache.camel.ExpressiondateExpression(String command) static org.apache.camel.ExpressiondateExpression(String command, String pattern) static org.apache.camel.ExpressiondateExpression(String commandWithOffsets, String timezone, String pattern) static org.apache.camel.ExpressionReturns the expression for the exchanges exception invoking methods defined in a simple OGNL notationstatic org.apache.camel.ExpressionexchangeOgnlExpression(String ognl) Returns the expression for the exchange invoking methods defined in a simple OGNL notationstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.Expressionstatic org.apache.camel.ExpressionheadersOgnlExpression(String ognl) Returns the expression for the exchanges inbound message header invoking methods defined in a simple OGNL notationstatic org.apache.camel.ExpressionjoinExpression(String expression, String separator, String prefix) Joins together the values from the expressionstatic org.apache.camel.ExpressionReturns the expression for the exchanges inbound message body converted to the given typestatic org.apache.camel.ExpressionmandatoryBodyOgnlExpression(String name, String ognl) Returns the expression for the exchanges inbound message body converted to the given type and invoking methods on the converted body defined in a simple OGNL notationstatic org.apache.camel.ExpressionmessageHistoryExpression(boolean detailed) Returns the message history (including exchange details or not)static org.apache.camel.ExpressionmessageOgnlExpression(String name, String ognl) Returns the expression for the message converted to the given type and invoking methods on the converted message defined in a simple OGNL notationstatic org.apache.camel.ExpressionnewEmptyExpression(String type) Returns a new empty object of the given typestatic org.apache.camel.ExpressionReturns the expression for thenullvaluestatic org.apache.camel.ExpressionpropertyOgnlExpression(String ognl) Returns an expression for the property value of exchange with the given name invoking methods defined in a simple OGNL notationstatic org.apache.camel.ExpressionrandomExpression(int max) Returns a random number between 0 and max (exclusive)static org.apache.camel.ExpressionrandomExpression(int min, int max) Returns a random number between min and max (exclusive)static org.apache.camel.ExpressionrandomExpression(String min, String max) Returns a random number between min and max (exclusive)static org.apache.camel.ExpressionskipExpression(String expression, int number) Returns an iterator to skip (iterate) the given expressionstatic org.apache.camel.ExpressionskipIteratorExpression(org.apache.camel.Expression expression, int skip) static org.apache.camel.ExpressiontypeExpression(String name) Returns an expression for a type valuestatic org.apache.camel.ExpressionuuidExpression(String generator) Returns a uuid string based on the given generator (default, classic, short, simple)
-
Method Details
-
headersOgnlExpression
Returns the expression for the exchanges inbound message header invoking methods defined in a simple OGNL notation- Parameters:
ognl- methods to invoke on the header in a simple OGNL syntax
-
messageHistoryExpression
public static org.apache.camel.Expression messageHistoryExpression(boolean detailed) Returns the message history (including exchange details or not) -
collateExpression
Returns an iterator to collate (iterate) the given expression -
skipExpression
Returns an iterator to skip (iterate) the given expression -
joinExpression
public static org.apache.camel.Expression joinExpression(String expression, String separator, String prefix) Joins together the values from the expression -
randomExpression
Returns a random number between min and max (exclusive) -
randomExpression
public static org.apache.camel.Expression randomExpression(int max) Returns a random number between 0 and max (exclusive) -
randomExpression
public static org.apache.camel.Expression randomExpression(int min, int max) Returns a random number between min and max (exclusive) -
newEmptyExpression
Returns a new empty object of the given type -
uuidExpression
Returns a uuid string based on the given generator (default, classic, short, simple) -
fileNameExpression
public static org.apache.camel.Expression fileNameExpression() -
fileOnlyNameExpression
public static org.apache.camel.Expression fileOnlyNameExpression() -
fileNameNoExtensionExpression
public static org.apache.camel.Expression fileNameNoExtensionExpression() -
fileNameNoExtensionSingleExpression
public static org.apache.camel.Expression fileNameNoExtensionSingleExpression() -
fileOnlyNameNoExtensionExpression
public static org.apache.camel.Expression fileOnlyNameNoExtensionExpression() -
fileOnlyNameNoExtensionSingleExpression
public static org.apache.camel.Expression fileOnlyNameNoExtensionSingleExpression() -
fileExtensionExpression
public static org.apache.camel.Expression fileExtensionExpression() -
fileExtensionSingleExpression
public static org.apache.camel.Expression fileExtensionSingleExpression() -
fileParentExpression
public static org.apache.camel.Expression fileParentExpression() -
filePathExpression
public static org.apache.camel.Expression filePathExpression() -
fileAbsolutePathExpression
public static org.apache.camel.Expression fileAbsolutePathExpression() -
fileAbsoluteExpression
public static org.apache.camel.Expression fileAbsoluteExpression() -
fileSizeExpression
public static org.apache.camel.Expression fileSizeExpression() -
fileLastModifiedExpression
public static org.apache.camel.Expression fileLastModifiedExpression() -
dateExpression
-
dateExpression
-
dateExpression
-
skipIteratorExpression
public static org.apache.camel.Expression skipIteratorExpression(org.apache.camel.Expression expression, int skip) -
nullExpression
public static org.apache.camel.Expression nullExpression()Returns the expression for thenullvalue -
mandatoryBodyOgnlExpression
Returns the expression for the exchanges inbound message body converted to the given type and invoking methods on the converted body defined in a simple OGNL notation -
mandatoryBodyExpression
Returns the expression for the exchanges inbound message body converted to the given type -
messageOgnlExpression
Returns the expression for the message converted to the given type and invoking methods on the converted message defined in a simple OGNL notation -
bodyOgnlExpression
Returns the expression for the exchanges inbound message body converted to the given type and invoking methods on the converted body defined in a simple OGNL notation -
exchangeOgnlExpression
Returns the expression for the exchange invoking methods defined in a simple OGNL notation- Parameters:
ognl- methods to invoke on the exchange in a simple OGNL syntax
-
camelContextOgnlExpression
Returns the expression for the exchanges camelContext invoking methods defined in a simple OGNL notation- Parameters:
ognl- methods to invoke on the context in a simple OGNL syntax
-
bodyOgnlExpression
Returns the expression for the exchanges inbound message body invoking methods defined in a simple OGNL notation- Parameters:
ognl- methods to invoke on the body in a simple OGNL syntax
-
cacheExpression
public static org.apache.camel.Expression cacheExpression(org.apache.camel.Expression expression) Returns an expression that caches the evaluation of another expression and returns the cached value, to avoid re-evaluating the expression.- Parameters:
expression- the target expression to cache- Returns:
- the cached value
-
typeExpression
Returns an expression for a type value- Parameters:
name- the type name- Returns:
- an expression object which will return the type value
-
propertyOgnlExpression
Returns an expression for the property value of exchange with the given name invoking methods defined in a simple OGNL notation- Parameters:
ognl- methods to invoke on the property in a simple OGNL syntax
-
exchangeExceptionOgnlExpression
Returns the expression for the exchanges exception invoking methods defined in a simple OGNL notation- Parameters:
ognl- methods to invoke on the body in a simple OGNL syntax
-