edu.udo.cs.ie.cowbots.elp.testparser
Class ELPParser

Package class diagram package ELPParser
java.lang.Object
  extended by edu.udo.cs.ie.cowbots.elp.testparser.ELPParser
All Implemented Interfaces:
ELPParserConstants

public class ELPParser
extends java.lang.Object
implements ELPParserConstants

modified delp parser for extended logic programs


Field Summary
private  java.util.List<int[]> jj_expentries
           
private  int[] jj_expentry
           
private  int jj_gen
           
(package private)  SimpleCharStream jj_input_stream
           
private  int jj_kind
           
private  int[] jj_la1
           
private static int[] jj_la1_0
           
 Token jj_nt
          Next token.
private  int jj_ntk
           
 Token token
          Current token.
 ELPParserTokenManager token_source
          Generated Token Manager.
 
Fields inherited from interface edu.udo.cs.ie.cowbots.elp.testparser.ELPParserConstants
AGGREG, ARITH, COLON, COMP, DEFAULT, EOF, INT, LBRA, MAXINT, NAME, NOT, RAUTE, RBRA, tokenImage
 
Constructor Summary
ELPParser(ELPParserTokenManager tm)
          Constructor with generated Token Manager.
ELPParser(java.io.InputStream stream)
          Constructor with InputStream.
ELPParser(java.io.InputStream stream, java.lang.String encoding)
          Constructor with InputStream and supplied encoding
ELPParser(java.io.Reader stream)
          Constructor.
 
Method Summary
 ELPAtom Atom(ELP delp)
           
 void disable_tracing()
          Disable tracing.
 void enable_tracing()
          Enable tracing.
 void Expression(ELP delp)
           
 ParseException generateParseException()
          Generate ParseException.
 Token getNextToken()
          Get the next Token.
 Token getToken(int index)
          Get the specific Token.
private  Token jj_consume_token(int kind)
           
private static void jj_la1_init_0()
           
private  int jj_ntk()
           
 ELPLiteral Literal(ELP delp)
           
static void main(java.lang.String[] args)
           
static ELP parse(java.lang.String filename)
          some modifications of the dlp parser to parse extended logic programs with arithmetical expressions.
 void ReInit(ELPParserTokenManager tm)
          Reinitialise.
 void ReInit(java.io.InputStream stream)
          Reinitialise.
 void ReInit(java.io.InputStream stream, java.lang.String encoding)
          Reinitialise.
 void ReInit(java.io.Reader stream)
          Reinitialise.
 SymbolicSet SymSet(ELP elp)
           
 java.lang.String Term(ELP delp)
           
 ELP Theory()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

token_source

public ELPParserTokenManager token_source
Generated Token Manager.


jj_input_stream

SimpleCharStream jj_input_stream

token

public Token token
Current token.


jj_nt

public Token jj_nt
Next token.


jj_ntk

private int jj_ntk

jj_gen

private int jj_gen

jj_la1

private final int[] jj_la1

jj_la1_0

private static int[] jj_la1_0

jj_expentries

private java.util.List<int[]> jj_expentries

jj_expentry

private int[] jj_expentry

jj_kind

private int jj_kind
Constructor Detail

ELPParser

public ELPParser(java.io.InputStream stream)
Constructor with InputStream.


ELPParser

public ELPParser(java.io.InputStream stream,
                 java.lang.String encoding)
Constructor with InputStream and supplied encoding


ELPParser

public ELPParser(java.io.Reader stream)
Constructor.


ELPParser

public ELPParser(ELPParserTokenManager tm)
Constructor with generated Token Manager.

Method Detail

parse

public static ELP parse(java.lang.String filename)
                 throws ParseException,
                        java.io.FileNotFoundException
some modifications of the dlp parser to parse extended logic programs with arithmetical expressions.

Throws:
ParseException
java.io.FileNotFoundException

main

public static void main(java.lang.String[] args)

Theory

public final ELP Theory()
                 throws ParseException
Throws:
ParseException

Expression

public final void Expression(ELP delp)
                      throws ParseException
Throws:
ParseException

Literal

public final ELPLiteral Literal(ELP delp)
                         throws ParseException
Throws:
ParseException

Atom

public final ELPAtom Atom(ELP delp)
                   throws ParseException
Throws:
ParseException

SymSet

public final SymbolicSet SymSet(ELP elp)
                         throws ParseException
Throws:
ParseException

Term

public final java.lang.String Term(ELP delp)
                            throws ParseException
Throws:
ParseException

jj_la1_init_0

private static void jj_la1_init_0()

ReInit

public void ReInit(java.io.InputStream stream)
Reinitialise.


ReInit

public void ReInit(java.io.InputStream stream,
                   java.lang.String encoding)
Reinitialise.


ReInit

public void ReInit(java.io.Reader stream)
Reinitialise.


ReInit

public void ReInit(ELPParserTokenManager tm)
Reinitialise.


jj_consume_token

private Token jj_consume_token(int kind)
                        throws ParseException
Throws:
ParseException

getNextToken

public final Token getNextToken()
Get the next Token.


getToken

public final Token getToken(int index)
Get the specific Token.


jj_ntk

private int jj_ntk()

generateParseException

public ParseException generateParseException()
Generate ParseException.


enable_tracing

public final void enable_tracing()
Enable tracing.


disable_tracing

public final void disable_tracing()
Disable tracing.