org.outerj.daisy.query
Class QueryParser

java.lang.Object
  extended by org.outerj.daisy.query.QueryParser
All Implemented Interfaces:
QueryParserConstants

public class QueryParser
extends java.lang.Object
implements QueryParserConstants


Field Summary
 Token jj_nt
           
 boolean lookingAhead
           
 Token token
           
 QueryParserTokenManager token_source
           
 
Fields inherited from interface org.outerj.daisy.query.QueryParserConstants
ADD, AND, ASC, BETWEEN, COMMA, CUSTOMFIELDNAME, DEFAULT, DESC, DIGIT, DIVIDE, DOES_NOT_HAVE_VARIANT, EOF, EQ, FIELDNAME, FULL_TEXT, GT, GTEQ, HAS_ALL, HAS_ANY, HAS_EXACTLY, HAS_NONE, HAS_PART, HAS_PART_WITH_MIMETYPE, ID, IN, IN_COLLECTION, INTEGER, IS_LINKED, IS_NOT_LINKED, IS_NOT_NULL, IS_NULL, LETTER, LIKE, LIMIT, LINKS_FROM, LINKS_FROM_VARIANT, LINKS_TO, LINKS_TO_VARIANT, LITERAL, LPAREN, LT, LTEQ, MULTIPLY, NAME, NOT, NOTEQ, NUMBER, OPTION, OR, ORDER_BY, OTHERS, PARTNAME, RPAREN, SELECT, SUBSTRACT, TEXT, tokenImage, TRUE, WHERE
 
Constructor Summary
QueryParser(java.io.InputStream stream)
           
QueryParser(QueryParserTokenManager tm)
           
QueryParser(java.io.Reader stream)
           
 
Method Summary
 Expression andExpression()
           
 PredicateExpr betweenExpression(boolean not, Identifier identifier)
           
 void disable_tracing()
           
 DoesNotHaveVariant doesNotHaveVariant()
           
 void enable_tracing()
           
 Expression expression()
           
 java.lang.Object[] fullTextClause()
          Returns array containing two items: first is a string containing the fulltext query, the second is a PredicateExpr containing further conditions.
 ParseException generateParseException()
           
 Token getNextToken()
           
 Token getToken(int index)
           
 Expression grouping()
           
 HasPart hasPart()
           
 HasPartWithMimeType hasPartWithMimeType()
           
 InCollection inCollection()
           
 PredicateExpr inExpression(boolean not, Identifier identifier)
           
 IsLinked isLinked()
           
 IsLinked isNotLinked()
           
 PredicateExpr isNotNull(Identifier identifier)
           
 PredicateExpr isNull(Identifier identifier)
           
 PredicateExpr likeExpression(boolean not, Identifier identifier)
           
 int limitClause()
           
 LinksToOrFrom linksToOrFrom()
           
 LinksToOrFrom linksToOrFromVariant()
           
 PredicateExpr multiArgPredicate(Identifier identifier)
           
 Expression multValueExpr()
           
 java.util.Map optionClause()
           
 java.lang.Object[] orderByClause()
           
 void orderByItem(ValueExprList identifiers, java.util.List directions)
           
 Expression orExpression()
           
 Query query()
           
 void ReInit(java.io.InputStream stream)
           
 void ReInit(QueryParserTokenManager tm)
           
 void ReInit(java.io.Reader stream)
           
 ValueExprList selectClause()
           
 PredicateExpr standAloneWhereClause()
           
 ValueExpr subValueExpr()
           
 Expression sumValueExpr()
           
 Expression unaryExpression()
           
 Expression valueExpr()
           
 ValueExprList valueExprList()
           
 PredicateExpr whereClause()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

token_source

public QueryParserTokenManager token_source

token

public Token token

jj_nt

public Token jj_nt

lookingAhead

public boolean lookingAhead
Constructor Detail

QueryParser

public QueryParser(java.io.InputStream stream)

QueryParser

public QueryParser(java.io.Reader stream)

QueryParser

public QueryParser(QueryParserTokenManager tm)
Method Detail

whereClause

public final PredicateExpr whereClause()
                                throws ParseException
Throws:
ParseException

standAloneWhereClause

public final PredicateExpr standAloneWhereClause()
                                          throws ParseException
Throws:
ParseException

orExpression

public final Expression orExpression()
                              throws ParseException
Throws:
ParseException

andExpression

public final Expression andExpression()
                               throws ParseException
Throws:
ParseException

expression

public final Expression expression()
                            throws ParseException
Throws:
ParseException

grouping

public final Expression grouping()
                          throws ParseException
Throws:
ParseException

unaryExpression

public final Expression unaryExpression()
                                 throws ParseException
Throws:
ParseException

valueExpr

public final Expression valueExpr()
                           throws ParseException
Throws:
ParseException

sumValueExpr

public final Expression sumValueExpr()
                              throws ParseException
Throws:
ParseException

multValueExpr

public final Expression multValueExpr()
                               throws ParseException
Throws:
ParseException

subValueExpr

public final ValueExpr subValueExpr()
                             throws ParseException
Throws:
ParseException

isNull

public final PredicateExpr isNull(Identifier identifier)
                           throws ParseException
Throws:
ParseException

isNotNull

public final PredicateExpr isNotNull(Identifier identifier)
                              throws ParseException
Throws:
ParseException

multiArgPredicate

public final PredicateExpr multiArgPredicate(Identifier identifier)
                                      throws ParseException
Throws:
ParseException

betweenExpression

public final PredicateExpr betweenExpression(boolean not,
                                             Identifier identifier)
                                      throws ParseException
Throws:
ParseException

inExpression

public final PredicateExpr inExpression(boolean not,
                                        Identifier identifier)
                                 throws ParseException
Throws:
ParseException

likeExpression

public final PredicateExpr likeExpression(boolean not,
                                          Identifier identifier)
                                   throws ParseException
Throws:
ParseException

inCollection

public final InCollection inCollection()
                                throws ParseException
Throws:
ParseException

query

public final Query query()
                  throws ParseException
Throws:
ParseException

selectClause

public final ValueExprList selectClause()
                                 throws ParseException
Throws:
ParseException

valueExprList

public final ValueExprList valueExprList()
                                  throws ParseException
Throws:
ParseException

orderByClause

public final java.lang.Object[] orderByClause()
                                       throws ParseException
Throws:
ParseException

orderByItem

public final void orderByItem(ValueExprList identifiers,
                              java.util.List directions)
                       throws ParseException
Throws:
ParseException

limitClause

public final int limitClause()
                      throws ParseException
Throws:
ParseException

optionClause

public final java.util.Map optionClause()
                                 throws ParseException
Throws:
ParseException

fullTextClause

public final java.lang.Object[] fullTextClause()
                                        throws ParseException
Returns array containing two items: first is a string containing the fulltext query, the second is a PredicateExpr containing further conditions. The second one is optional, and can thus be null.

Throws:
ParseException

linksToOrFrom

public final LinksToOrFrom linksToOrFrom()
                                  throws ParseException
Throws:
ParseException

linksToOrFromVariant

public final LinksToOrFrom linksToOrFromVariant()
                                         throws ParseException
Throws:
ParseException

isLinked

public final IsLinked isLinked()
                        throws ParseException
Throws:
ParseException

isNotLinked

public final IsLinked isNotLinked()
                           throws ParseException
Throws:
ParseException

hasPartWithMimeType

public final HasPartWithMimeType hasPartWithMimeType()
                                              throws ParseException
Throws:
ParseException

hasPart

public final HasPart hasPart()
                      throws ParseException
Throws:
ParseException

doesNotHaveVariant

public final DoesNotHaveVariant doesNotHaveVariant()
                                            throws ParseException
Throws:
ParseException

ReInit

public void ReInit(java.io.InputStream stream)

ReInit

public void ReInit(java.io.Reader stream)

ReInit

public void ReInit(QueryParserTokenManager tm)

getNextToken

public final Token getNextToken()

getToken

public final Token getToken(int index)

generateParseException

public ParseException generateParseException()

enable_tracing

public final void enable_tracing()

disable_tracing

public final void disable_tracing()


Copyright © -2012 . All Rights Reserved.