FirteX-高性能全文索引和检索平台

API Documentation


首页 | 名字空间列表 | 类继承关系 | 组合类型列表 | $(BL\录(B | 文件列表 | 名字空间成员 | 组合类型成员 | 文件成员

QueryParserConstants.h

浏览该文件的文档。
00001 #ifndef _QUERYPARSERCONSTANTS_H
00002 #define _QUERYPARSERCONSTANTS_H
00003 
00004 #if _MSC_VER > 1000
00005 #pragma once
00006 #endif // _MSC_VER > 1000
00007 
00008 
00009 #include "../utility/StdHeader.h"
00010 #include <sstream>
00011 #include <string>
00012 
00013 using namespace std;
00014 
00015 namespace firtex
00016 {
00017         namespace search
00018         {
00019 
00020 #define RANGE_QUERY
00021 
00022                 enum QueryTokenTypes
00023                 {
00024                         AND_,
00025                         OR,
00026                         NOT,
00027                         PLUS,
00028                         MINUS,
00029                         LPAREN,
00030                         RPAREN,
00031                         COLON,
00032                         CARAT,
00033                         QUOTED,
00034                         TERM,
00035                         SLOP,
00036 #ifndef NO_FUZZY_QUERY
00037                         FUZZY,
00038 #endif
00039 #ifndef NO_PREFIX_QUERY
00040                         PREFIXTERM,
00041 #endif
00042 #ifndef NO_WILDCARD_QUERY
00043                         WILDTERM,
00044 #endif
00045 #ifdef RANGE_QUERY
00046                         RANGEIN,
00047                         RANGEEX,
00048 #endif
00049                         NUMBER,
00050                         EOF_
00051                 };
00052 
00053                 class CQueryParserException : public CFirteException
00054                 {
00055                 public:
00056                         CQueryParserException(const string& msg,int line,int column):CFirteException(QUERY_PARSE_ERROR)
00057                         {
00058                                 stringstream ss;
00059                                 ss << s_errorStrings[QUERY_PARSE_ERROR] << ":" << msg << " at line:" << line << " column:"<<column;
00060 
00061                                 m_what = ss.str();
00062                         }
00063                         ~CQueryParserException(){}              
00064                 };      
00065         }
00066 }
00067 
00068 #endif
00069 

http://www.firtex.org http://www.sourceforge.net/projects/firtex