Beispiel #1
0
 public PEParser()
 {
     lookAheadBuffer = new Token[_lookAhead];
 }
Beispiel #2
0
 protected bool isEndOfInput(Token t)
 {
     return (t.getType() == (int)LogicTokenTypes.EOI);
 }
Beispiel #3
0
 private bool notToken(Token t)
 {
     if ((t.getType() == (int)LogicTokenTypes.CONNECTOR)
             && (t.getText().Equals("NOT")))
     {
         return true;
     }
     else
     {
         return false;
     }
 }
Beispiel #4
0
 private bool predicate(Token t)
 {
     if ((t.getType() == (int)LogicTokenTypes.PREDICATE))
     {
         return true;
     }
     else
     {
         return false;
     }
 }
Beispiel #5
0
        private bool term(Token t)
        {
            if ((t.getType() == (int)LogicTokenTypes.FUNCTION)
                    || (t.getType() == (int)LogicTokenTypes.CONSTANT)
                    || (t.getType() == (int)LogicTokenTypes.VARIABLE))
            {
                return true;
            }
            else
            {
                return false;
            }

        }
Beispiel #6
0
 private bool lParen(Token t)
 {
     if (t.getType() == (int)LogicTokenTypes.LPAREN)
     {
         return true;
     }
     else
     {
         return false;
     }
 }
Beispiel #7
0
 private bool binaryConnector(Token t)
 {
     if ((t.getType() == (int)LogicTokenTypes.CONNECTOR)
             && (!(t.getText().Equals("NOT"))))
     {
         return true;
     }
     else
     {
         return false;
     }
 }