prolog
Class PrologParser

java.lang.Object
  |
  +--exp.Parser
        |
        +--prolog.PrologParser

public class PrologParser
extends Parser

PrologParser Analizzatore sintattico che accetta la sintassi Prolog

Version:
2/2/2000
Author:
Marco Chiesi

Fields inherited from class exp.Parser
curToken, lex, msgOut
 
Constructor Summary
PrologParser(Lexer lex)
          Costruttore
PrologParser(Lexer lex, OutputDevice msgOut)
          Costruttore
 
Method Summary
protected  Sexp argList()
          Lettura di una lista di argomenti di una funzione
protected  Sexp atom()
          Lettura di un goal
protected  Sexp body(Sexp head)
          Lettura del corpo di una clausola
protected  Sexp bodyElem(Sexp head)
          Lettura di un elemento del corpo
protected  Sexp clause()
          Lettura di una clausola
protected  Sexp funcPred()
          Lettura di una funzione
protected  Sexp list()
          Lettura di una lista compresa tra []
protected  Sexp operator()
          Lettura di un operatore
protected  Sexp operPred()
          Lettura di un predicato con operatori
 Sexp program()
          Lettura di un programma
 Clause query()
          Lettura di una query
protected  Sexp readSexp()
          Lettura di un'espressione
protected  Sexp term()
          Lettura di un termine
protected  Sexp termList()
          Lettura di una lista di termini
 
Methods inherited from class exp.Parser
atEOF, nextToken, parse, print, println
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PrologParser

public PrologParser(Lexer lex,
                    OutputDevice msgOut)
             throws java.lang.Exception
Costruttore

PrologParser

public PrologParser(Lexer lex)
             throws java.lang.Exception
Costruttore
Method Detail

readSexp

protected Sexp readSexp()
                 throws java.lang.Exception
Lettura di un'espressione
Overrides:
readSexp in class Parser

program

public Sexp program()
             throws java.lang.Exception
Lettura di un programma

query

public Clause query()
             throws java.lang.Exception
Lettura di una query

clause

protected Sexp clause()
               throws java.lang.Exception
Lettura di una clausola

bodyElem

protected Sexp bodyElem(Sexp head)
                 throws java.lang.Exception
Lettura di un elemento del corpo

body

protected Sexp body(Sexp head)
             throws java.lang.Exception
Lettura del corpo di una clausola

atom

protected Sexp atom()
             throws java.lang.Exception
Lettura di un goal

operPred

protected Sexp operPred()
                 throws java.lang.Exception
Lettura di un predicato con operatori

operator

protected Sexp operator()
                 throws java.lang.Exception
Lettura di un operatore

term

protected Sexp term()
             throws java.lang.Exception
Lettura di un termine

list

protected Sexp list()
             throws java.lang.Exception
Lettura di una lista compresa tra []

termList

protected Sexp termList()
                 throws java.lang.Exception
Lettura di una lista di termini

funcPred

protected Sexp funcPred()
                 throws java.lang.Exception
Lettura di una funzione

argList

protected Sexp argList()
                throws java.lang.Exception
Lettura di una lista di argomenti di una funzione