xtc.parser
Class PParser

java.lang.Object
  extended by xtc.parser.ParserBase
      extended by xtc.parser.PParser

public final class PParser
extends ParserBase

Packrat parser for grammar xtc.parser.PGrammar.

This class has been generated by the Rats! parser generator, version 2.1.0, (C) 2004-2011 Robert Grimm.


Field Summary
protected  PParserState yyState
          The global state object.
 
Fields inherited from class xtc.parser.ParserBase
FIRST_COLUMN, FIRST_LINE, INCR_SIZE, INIT_SIZE, NEWLINE, yyColumns, yyCount, yyData, yyEOF, yyReader
 
Constructor Summary
PParser(java.io.Reader reader, java.lang.String file)
          Create a new packrat parser.
PParser(java.io.Reader reader, java.lang.String file, int size)
          Create a new packrat parser.
 
Method Summary
protected  Column newColumn()
          Create a new column.
 Result pAttribute(int yyStart)
          Parse nonterminal xtc.parser.PGrammar.Attribute.
 Result pModule(int yyStart)
          Parse nonterminal xtc.parser.PGrammar.Module.
 
Methods inherited from class xtc.parser.ParserBase
apply, apply, cast, cast, character, column, difference, format, isEOF, lineAt, location, peek, resetTo, setLocation, setLocation, signal, value
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

yyState

protected final PParserState yyState
The global state object.

Constructor Detail

PParser

public PParser(java.io.Reader reader,
               java.lang.String file)
Create a new packrat parser.

Parameters:
reader - The reader.
file - The file name.

PParser

public PParser(java.io.Reader reader,
               java.lang.String file,
               int size)
Create a new packrat parser.

Parameters:
reader - The file reader.
file - The file name.
size - The file size.
Method Detail

newColumn

protected Column newColumn()
Description copied from class: ParserBase
Create a new column. A concrete implementation of this method should simply return a new memoization table column.

Specified by:
newColumn in class ParserBase
Returns:
A new memoization table column.

pModule

public Result pModule(int yyStart)
               throws java.io.IOException
Parse nonterminal xtc.parser.PGrammar.Module.

Parameters:
yyStart - The index.
Returns:
The result.
Throws:
java.io.IOException - Signals an I/O error.

pAttribute

public Result pAttribute(int yyStart)
                  throws java.io.IOException
Parse nonterminal xtc.parser.PGrammar.Attribute.

Parameters:
yyStart - The index.
Returns:
The result.
Throws:
java.io.IOException - Signals an I/O error.


Copyright © 2012. All Rights Reserved.