Jet.Pat
Class FinalPatternNode

java.lang.Object
  extended byJet.Pat.PatternNode
      extended byJet.Pat.FinalPatternNode

public class FinalPatternNode
extends PatternNode

A node in the graph representation of a pattern set, representing the end of a path, associated with a set of actions to be performed if that node is reached in pattern matching.


Field Summary
 java.util.Vector actions
           
 java.lang.String patternName
           
 
Fields inherited from class Jet.Pat.PatternNode
id
 
Constructor Summary
FinalPatternNode(Id id, java.lang.String patternName, java.util.Vector actions)
          Creates a FinalPatternNode with identifier i and set of actions acts.
 
Method Summary
 void eval(Document doc, int posn, java.util.HashMap bindings, PatternApplication patap)
          Method invoked when this node is reached during pattern matching; records the actions to be performed.
 java.lang.String toString()
          Creates a printable representation of the node, consisting of "-->" followed by representations of the associated actions.
 void toTree(javax.swing.tree.DefaultMutableTreeNode parent)
           
 
Methods inherited from class Jet.Pat.PatternNode
visit, visited
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

actions

public java.util.Vector actions

patternName

public java.lang.String patternName
Constructor Detail

FinalPatternNode

public FinalPatternNode(Id id,
                        java.lang.String patternName,
                        java.util.Vector actions)
Creates a FinalPatternNode with identifier i and set of actions acts.

Method Detail

eval

public void eval(Document doc,
                 int posn,
                 java.util.HashMap bindings,
                 PatternApplication patap)
Method invoked when this node is reached during pattern matching; records the actions to be performed. If this turns out to be the best (longest) pattern match, these actions will subsequently be performed.

Specified by:
eval in class PatternNode

toString

public java.lang.String toString()
Creates a printable representation of the node, consisting of "-->" followed by representations of the associated actions.


toTree

public void toTree(javax.swing.tree.DefaultMutableTreeNode parent)
Specified by:
toTree in class PatternNode