Raptor
Class NDRuleController

java.lang.Object
  extended by Raptor.NDRuleController

public class NDRuleController
extends java.lang.Object

Implements the correct NDRule when a first line and a rule have been selected.


Constructor Summary
NDRuleController(java.lang.String pRule, ProofLine pFirstLine, ProofBox pProof)
          Constructs a NDRuleController.
 
Method Summary
 void addLine(ProofLine pLine)
          Adds the given ProofLine to the proof as extra input.
 void apply()
          Called by RuleController to apply the RAPRule.
 boolean haveAll()
          Returns true if the rule has all of the required input lines.
 void initialise()
          Called by RuleController to add the first line to the rule.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NDRuleController

public NDRuleController(java.lang.String pRule,
                        ProofLine pFirstLine,
                        ProofBox pProof)
                 throws java.lang.Exception
Constructs a NDRuleController.

Parameters:
pRule - String representing the selected Rule
pFirstLine - the ProofLine which has been selected
pProof - the ProofBox which contains the selected line
Throws:
java.lang.Exception
Method Detail

initialise

public void initialise()
                throws java.lang.Exception
Called by RuleController to add the first line to the rule.

Throws:
java.lang.Exception

haveAll

public boolean haveAll()
Returns true if the rule has all of the required input lines.


apply

public void apply()
           throws java.lang.Exception
Called by RuleController to apply the RAPRule.

Throws:
java.lang.Exception

addLine

public void addLine(ProofLine pLine)
             throws java.lang.Exception
Adds the given ProofLine to the proof as extra input.

Parameters:
pLine - the ProofLine to be added to the proof
Throws:
java.lang.Exception