laser.regularlanguage.regularexpression
Interface REVisitor<L extends LabelInterface>

Type Parameters:
L - The type of Label associated with the REs.
All Known Implementing Classes:
AbstractREConverter, AbstractREtoDFAVisitor, AbstractREVisitor, ExtendedREToREConverter, REPrinter, RESimplifier, REtoDFABuilder, REtoDFAInfoPrinter, REtoNFAConverter, StringREtoREConverter

public interface REVisitor<L extends LabelInterface>

The REVisitor class implements the visitor pattern. It is the visitor type.

REFERENCES:

Gamma, Erich, Helm, Richard, Johnson, Ralph, and Vlissides, John. "Design Patterns: Elements of Reusable Object-Oriented Software". Reading, Massachusetts: Addison-Wesley Longman, Inc, 1995.

Author:
Heather M. Conboy (laser-software@cs.umass.edu)

Method Summary
 void caseChoiceNode(ChoiceNode<L> node, java.lang.Object context)
          Allows this Visitor to process the given ChoiceNode.
 void caseClassSetNode(ClassSetNode<L> node, java.lang.Object context)
          Allows this Visitor to process the given ClassSetNode.
 void caseConcatenationNode(ConcatenationNode<L> node, java.lang.Object context)
          Allows this Visitor to process the given ConcatenationNode.
 void caseDotNode(DotNode<L> node, java.lang.Object context)
          Allows this Visitor to process the given DotNode.
 void caseEmptyNode(EmptyNode<L> node, java.lang.Object context)
          Allows this REVisitor to process the given EmptyNode.
 void caseEpsilonNode(EpsilonNode<L> node, java.lang.Object context)
          Allows this REVisitor to process the given EpsilonNode.
 void caseExponentNode(ExponentNode<L> node, java.lang.Object context)
          Allows this Visitor to process the given ExponentNode.
 void caseKleenePlusNode(KleenePlusNode<L> node, java.lang.Object context)
          Allows this Visitor to process the given KleenePlusNode.
 void caseKleeneStarNode(KleeneStarNode<L> node, java.lang.Object context)
          Allows this Visitor to process the given KleeneStarNode.
 void caseLabelNode(LabelNode<L> node, java.lang.Object context)
          Allows this Visitor to process the given LabelNode.
 void caseNotClassSetNode(NotClassSetNode<L> node, java.lang.Object context)
          Allows this Visitor to process the given NotClassSetNode.
 void caseOptionNode(OptionNode<L> node, java.lang.Object context)
          Allows this Visitor to process the given OptionNode
 void defaultCase(java.lang.Object node)
          Performs the default action.
 

Method Detail

caseChoiceNode

void caseChoiceNode(ChoiceNode<L> node,
                    java.lang.Object context)
                    throws REVisitorException
Allows this Visitor to process the given ChoiceNode.

Parameters:
node - The ChoiceNode to be processed
context - The calling context
Throws:
REVisitorException - if an error occurs

caseConcatenationNode

void caseConcatenationNode(ConcatenationNode<L> node,
                           java.lang.Object context)
                           throws REVisitorException
Allows this Visitor to process the given ConcatenationNode.

Parameters:
node - The ConcatenationNode to be processed
context - The calling context
Throws:
REVisitorException - if an error occurs

caseDotNode

void caseDotNode(DotNode<L> node,
                 java.lang.Object context)
                 throws REVisitorException
Allows this Visitor to process the given DotNode.

Parameters:
node - The DotNode to be processed
context - The calling context
Throws:
REVisitorException - if an error occurs

caseEmptyNode

void caseEmptyNode(EmptyNode<L> node,
                   java.lang.Object context)
                   throws REVisitorException
Allows this REVisitor to process the given EmptyNode.

Parameters:
node - The EmptyNode to be processed
context - The calling context
Throws:
REVisitorException - if an error occurs

caseEpsilonNode

void caseEpsilonNode(EpsilonNode<L> node,
                     java.lang.Object context)
                     throws REVisitorException
Allows this REVisitor to process the given EpsilonNode.

Parameters:
node - The EpsilonNode to be processed
context - The calling context
Throws:
REVisitorException - if an error occurs

caseExponentNode

void caseExponentNode(ExponentNode<L> node,
                      java.lang.Object context)
                      throws REVisitorException
Allows this Visitor to process the given ExponentNode.

Parameters:
node - The ExponentNode to be processed
context - The calling context
Throws:
REVisitorException - if an error occurs

caseKleenePlusNode

void caseKleenePlusNode(KleenePlusNode<L> node,
                        java.lang.Object context)
                        throws REVisitorException
Allows this Visitor to process the given KleenePlusNode.

Parameters:
node - The KleenePlusNode to be processed
context - The calling context
Throws:
REVisitorException - if an error occurs

caseKleeneStarNode

void caseKleeneStarNode(KleeneStarNode<L> node,
                        java.lang.Object context)
                        throws REVisitorException
Allows this Visitor to process the given KleeneStarNode.

Parameters:
node - The KleeneStarNode to be processed
context - The calling context
Throws:
REVisitorException - if an error occurs

caseLabelNode

void caseLabelNode(LabelNode<L> node,
                   java.lang.Object context)
                   throws REVisitorException
Allows this Visitor to process the given LabelNode.

Parameters:
node - The LabelNode to be processed
context - The calling context
Throws:
REVisitorException - if an error occurs

caseClassSetNode

void caseClassSetNode(ClassSetNode<L> node,
                      java.lang.Object context)
                      throws REVisitorException
Allows this Visitor to process the given ClassSetNode.

Parameters:
node - The ClassSetNode to be processed
context - The calling context
Throws:
REVisitorException - if an error occurs

caseNotClassSetNode

void caseNotClassSetNode(NotClassSetNode<L> node,
                         java.lang.Object context)
                         throws REVisitorException
Allows this Visitor to process the given NotClassSetNode.

Parameters:
node - The NotClassSetNode to be processed
context - The calling context
Throws:
REVisitorException - if an error occurs

caseOptionNode

void caseOptionNode(OptionNode<L> node,
                    java.lang.Object context)
                    throws REVisitorException
Allows this Visitor to process the given OptionNode

Parameters:
node - The OptionNode to be processed
context - The calling context
Throws:
REVisitorException - if an error occurs

defaultCase

void defaultCase(java.lang.Object node)
                 throws REVisitorException
Performs the default action.

Parameters:
node - The Object to be processed
Throws:
REVisitorException - if an error occurs