@ComponentProfile(summary="Tests a static algorithm for a boolean result.", tag="condition") public class ConditionExpression extends ConditionImpl
This Condition
allows you to specify a boolean evaluated expression, with static values
and resolved metadata values.
If your expression evaluates to "true", then this condition passes.
Static values mixed with metadata values allow you to create boolean expressions, such as;
Example description | Example Expression |
---|---|
Is the metadata value identified by key "myKey" equal to the value 1 | %message{myKey} == 1 |
Is the metadata value identified by key "myKey" equal to the metadata item "myOtherKey" | %message{myKey} == %message{myOtherKey} |
Is the metadata value identified by key "myKey" greater than "myOtherKey" plus 100 | %message{myKey} > (%message{myOtherKey} + 100) |
In the adapter configuration file this class is aliased as expression which is the preferred alternative to the fully qualified classname when building your configuration.
log
Constructor and Description |
---|
ConditionExpression() |
Modifier and Type | Method and Description |
---|---|
boolean |
evaluate(AdaptrisMessage msg) |
java.lang.String |
getAlgorithm() |
void |
setAlgorithm(java.lang.String algorithm) |
ConditionExpression |
withAlgorithm(java.lang.String s) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
close, init, start, stop
public boolean evaluate(AdaptrisMessage msg) throws CoreException
CoreException
public java.lang.String getAlgorithm()
public void setAlgorithm(java.lang.String algorithm)
public ConditionExpression withAlgorithm(java.lang.String s)