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


 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
TermRangeQuery.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 TERMRANGEQUERY_H
8 #define TERMRANGEQUERY_H
9 
10 #include "MultiTermQuery.h"
11 
12 namespace Lucene {
13 
21 class LPPAPI TermRangeQuery : public MultiTermQuery {
22 public:
42  TermRangeQuery(const String& fieldName, StringValue lowerTerm, StringValue upperTerm, bool includeLower,
43  bool includeUpper, CollatorPtr collator = CollatorPtr());
44 
45  virtual ~TermRangeQuery();
46 
48 
49 protected:
50  StringValue lowerTerm;
51  StringValue upperTerm;
53  String field;
56 
57 public:
59 
61  String getField();
62 
64  String getLowerTerm();
65 
67  String getUpperTerm();
68 
70  bool includesLower();
71 
73  bool includesUpper();
74 
76  CollatorPtr getCollator();
77 
78  virtual LuceneObjectPtr clone(const LuceneObjectPtr& other = LuceneObjectPtr());
79  virtual String toString(const String& field);
80  virtual int32_t hashCode();
81  virtual bool equals(const LuceneObjectPtr& other);
82 
83 protected:
84  virtual FilteredTermEnumPtr getEnum(const IndexReaderPtr& reader);
85 };
86 
87 }
88 
89 #endif

clucene.sourceforge.net