Lucene++ - a full-featured, c++ search engine
API Documentation


 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
WildcardTermEnum.h
Go to the documentation of this file.
1 
2 // Copyright (c) 2009-2014 Alan Wright. All rights reserved.
3 // Distributable under the terms of either the Apache License (Version 2.0)
4 // or the GNU Lesser General Public License.
6 
7 #ifndef WILDCARDTERMENUM_H
8 #define WILDCARDTERMENUM_H
9 
10 #include "FilteredTermEnum.h"
11 
12 namespace Lucene {
13 
18 class LPPAPI WildcardTermEnum : public FilteredTermEnum {
19 public:
24  WildcardTermEnum(const IndexReaderPtr& reader, const TermPtr& term);
25 
26  virtual ~WildcardTermEnum();
27 
29 
30 public:
31  static const wchar_t WILDCARD_STRING;
32  static const wchar_t WILDCARD_CHAR;
33 
35  String field;
36  String text;
37  String pre;
38  int32_t preLen;
39  bool _endEnum;
40 
41 public:
42  virtual double difference();
43 
45  static bool wildcardEquals(const String& pattern, int32_t patternIdx, const String& string, int32_t stringIdx);
46 
47 protected:
48  virtual bool termCompare(const TermPtr& term);
49  virtual bool endEnum();
50 };
51 
52 }
53 
54 #endif

clucene.sourceforge.net