org.drools.semantics.java
Class BlockConsequence

java.lang.Object
  extended byorg.drools.semantics.java.BlockConsequence
All Implemented Interfaces:
Consequence, SemanticComponent, Serializable

public class BlockConsequence
extends Object
implements Consequence, Serializable

Java block semantics Consequence.

Author:
bob@werken.com
See Also:
Serialized Form

Nested Class Summary
static interface BlockConsequence.Script
           
 
Constructor Summary
BlockConsequence(String block, Rule rule)
          Construct.
 
Method Summary
 String getBlock()
          Retrieve the expression.
 void invoke(Tuple tuple, WorkingMemory workingMemory)
          Execute the consequence for the supplied matching Tuple.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BlockConsequence

public BlockConsequence(String block,
                        Rule rule)
                 throws Exception
Construct.

Parameters:
block - The statement block.
rule - The rule.
Method Detail

invoke

public void invoke(Tuple tuple,
                   WorkingMemory workingMemory)
            throws ConsequenceException
Execute the consequence for the supplied matching Tuple.

Specified by:
invoke in interface Consequence
Parameters:
tuple - The matching tuple.
workingMemory - The working memory session.
Throws:
ConsequenceException - If an error occurs while attempting to invoke the consequence.

getBlock

public String getBlock()
Retrieve the expression.

Returns:
The expression.


Copyright © 2001-2004 The Codehaus. All Rights Reserved.