org.drools.reteoo.impl
Class ConditionNodeImpl
java.lang.Object
|
+--org.drools.reteoo.impl.TupleSourceImpl
|
+--org.drools.reteoo.impl.ConditionNodeImpl
- All Implemented Interfaces:
- ConditionNode, TupleSink, TupleSinkImpl, TupleSource
- public class ConditionNodeImpl
- extends TupleSourceImpl
- implements ConditionNode, TupleSinkImpl
Node which filters ReteTuple
s.
Using a semantic Condition
, this node
may allow or disallow Tuples
to proceed
further through the Rete-OO network.
- Author:
- bob mcwhirter
- See Also:
ConditionNode
,
Condition
,
ReteTuple
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
ConditionNodeImpl
public ConditionNodeImpl(TupleSourceImpl tupleSource,
Condition condition)
- Construct.
- Parameters:
tupleSource
- The source of incoming Tuples
.condition
- The semantic Condition
.
getCondition
public Condition getCondition()
- Retrieve the
Condition
associated
with this node.
- Specified by:
getCondition
in interface ConditionNode
- Returns:
- The
Condition
.
getTupleDeclarations
public java.util.Set getTupleDeclarations()
- Retrieve the
Set
of Declaration
s
in the propagated Tuples
.
- Specified by:
getTupleDeclarations
in interface TupleSource
- Returns:
- The
Set
of Declarations
in progated Tuples
.
assertTuple
public void assertTuple(ReteTuple tuple,
WorkingMemory workingMemory)
throws AssertionException
- Assert a new
Tuple
.
- Specified by:
assertTuple
in interface TupleSinkImpl
- Parameters:
tuple
- The Tuple
being asserted.workingMemory
- The working memory seesion.- Throws:
AssertionException
- If an error occurs while asserting.
retractTuples
public void retractTuples(org.drools.reteoo.impl.TupleKey key,
WorkingMemory workingMemory)
throws RetractionException
- Retract tuples.
- Specified by:
retractTuples
in interface TupleSinkImpl
- Parameters:
key
- The tuple key.workingMemory
- The working memory seesion.- Throws:
RetractionException
- If an error occurs while retracting.
modifyTuples
public void modifyTuples(java.lang.Object trigger,
org.drools.reteoo.impl.TupleSet newTuples,
WorkingMemory workingMemory)
throws FactException
- Modify tuples.
- Specified by:
modifyTuples
in interface TupleSinkImpl
- Parameters:
trigger
- The root fact object.newTuples
- Modification replacement tuples.workingMemory
- The working memory session.- Throws:
FactException
- If an error occurs while modifying.
toString
public java.lang.String toString()
- Produce a debug string.
- Overrides:
toString
in class java.lang.Object
- Returns:
- The debug string.
Copyright © 2001-2002 The Werken Company. All Rights Reserved.