1 #ifndef _BooleanQueryParser_h_
2 #define _BooleanQueryParser_h_
3 
4 //
5 // BooleanQueryParser.h
6 //
7 // BooleanQueryParser: Query parser for full-blown boolean expressions
8 //
9 // Part of the ht://Dig package   <http://www.htdig.org/>
10 // Copyright (c) 1995-2004 The ht://Dig Group
11 // For copyright details, see the file COPYING in your distribution
12 // or the GNU Library General Public License (LGPL) version 2 or later
13 // <http://www.gnu.org/copyleft/lgpl.html>
14 //
15 // $Id: BooleanQueryParser.h,v 1.4 2004/05/28 13:15:24 lha Exp $
16 //
17 
18 #include "QueryParser.h"
19 #include "BooleanLexer.h"
20 
21 class BooleanQueryParser : public QueryParser
22 {
23 public:
BooleanQueryParser()24 	BooleanQueryParser() {}
~BooleanQueryParser()25 	~BooleanQueryParser() {}
26 
27 private:
28 	// recursive parse levels
29 	// returning constructed query trees
30 	Query *ParseExpression();
31 	Query *ParseAnd();
32 	Query *ParseNot();
33 	Query *ParseNear();
34 	Query *ParseFactor();
35 
36 	// lexer access needed by parent class
Token()37 	QueryLexer &Token() { return token; }
38 
39 	// the lexical analyzer
40 	BooleanLexer token;
41 };
42 
43 #endif
44