xtc.parser
Class Tokenizer.Tester

java.lang.Object
  extended by xtc.tree.Visitor
      extended by xtc.parser.Tokenizer.Tester
Enclosing class:
Tokenizer

public static class Tokenizer.Tester
extends Visitor

Visitor to determine which productions are lexical.


Field Summary
protected  Analyzer analyzer
          The analyzer utility.
protected  boolean isLexical
          The flag for whether the current production is lexical.
protected  Runtime runtime
          The runtime.
 
Constructor Summary
Tokenizer.Tester(Runtime runtime, Analyzer analyzer)
          Create a new lexical tester.
 
Method Summary
protected  void mark(Production p)
          Mark the specified production as lexical.
 void visit(Action a)
          Visit the specified action.
 void visit(Binding b)
          Visit the specified binding.
 void visit(CharCase c)
          Visit the specified character case.
 void visit(CharSwitch s)
          Visit the specified character switch.
 void visit(Element e)
          Visit the specified element.
 void visit(Module m)
          Visit the specified grammar.
 void visit(NodeMarker m)
          Visit the specified node marker.
 void visit(NonTerminal nt)
          Visit the specified nonterminal.
 void visit(NullLiteral l)
          Visit the specified null literal.
 void visit(OrderedChoice c)
          Visit the specified ordered choice.
 void visit(ParserAction pa)
          Visit the specified parser action.
 void visit(Production p)
          Visit the specified production.
 void visit(SemanticPredicate p)
          Visit the specified semantic predicate.
 void visit(Sequence s)
          Visit the specified sequence.
 void visit(Terminal t)
          Visit the specified terminal.
 void visit(UnaryOperator op)
          Visit the specified unary operator.
 
Methods inherited from class xtc.tree.Visitor
dispatch, equals, hashCode, iterate, map, mapInPlace, unableToVisit, visit
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

runtime

protected final Runtime runtime
The runtime.


analyzer

protected final Analyzer analyzer
The analyzer utility.


isLexical

protected boolean isLexical
The flag for whether the current production is lexical.

Constructor Detail

Tokenizer.Tester

public Tokenizer.Tester(Runtime runtime,
                        Analyzer analyzer)
Create a new lexical tester.

Parameters:
runtime - The runtime.
analyzer - The analyzer utility.
Method Detail

mark

protected void mark(Production p)
Mark the specified production as lexical.

Parameters:
p - The production.

visit

public void visit(Module m)
Visit the specified grammar.


visit

public void visit(Production p)
Visit the specified production.


visit

public void visit(OrderedChoice c)
Visit the specified ordered choice.


visit

public void visit(Sequence s)
Visit the specified sequence.


visit

public void visit(SemanticPredicate p)
Visit the specified semantic predicate.


visit

public void visit(Binding b)
Visit the specified binding.


visit

public void visit(NonTerminal nt)
Visit the specified nonterminal.


visit

public void visit(CharCase c)
Visit the specified character case.


visit

public void visit(CharSwitch s)
Visit the specified character switch.


visit

public void visit(Terminal t)
Visit the specified terminal.


visit

public void visit(UnaryOperator op)
Visit the specified unary operator. This method provides the default implementation for repetitions, options, syntactic predicates, voided elements, and string matches.


visit

public void visit(NullLiteral l)
Visit the specified null literal.


visit

public void visit(NodeMarker m)
Visit the specified node marker.


visit

public void visit(Action a)
Visit the specified action.


visit

public void visit(ParserAction pa)
Visit the specified parser action.


visit

public void visit(Element e)
Visit the specified element. This method provides the default implementation for parse tree nodes and value elements.



Copyright © 2012. All Rights Reserved.