org.drools.semantics.java
Class JavaCondition
java.lang.Object
org.drools.semantics.java.JavaCondition
- All Implemented Interfaces:
- Condition, SemanticComponent, java.io.Serializable
- public class JavaCondition
- extends java.lang.Object
- implements java.io.Serializable, Condition
Java expression semantics Condition
.
- See Also:
- Serialized Form
-
Constructor Summary |
protected |
JavaCondition(Rule rule,
int id,
java.lang.String expression)
Construct. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
JavaCondition
protected JavaCondition(Rule rule,
int id,
java.lang.String expression)
throws java.lang.Exception
- Construct.
- Throws:
javax.naming.ConfigurationException
- If an error occurs while attempting to perform configuration.
java.lang.Exception
- Parameters:
expression
- The expression.rule
- The rule.
isAllowed
public boolean isAllowed(Tuple tuple)
throws ConditionException
- Determine if the supplied
Tuple
is allowed by this
condition.
- Specified by:
isAllowed
in interface Condition
- Throws:
ConditionException
- if an error occurs during filtering.- Parameters:
tuple
- The Tuple
to test.
- Returns:
true
if the Tuple
passes this
condition, else false
.
getRequiredTupleMembers
public Declaration[] getRequiredTupleMembers()
- Retrieve the
Declaration
s required for evaluating the
expression.
- Specified by:
getRequiredTupleMembers
in interface Condition
- Returns:
- The required declarations.
hashCode
public int hashCode()
equals
public boolean equals(java.lang.Object object)
toString
public java.lang.String toString()