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


 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
StopFilter.h
Go to the documentation of this file.
1 // Copyright (c) 2009-2011 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 STOPFILTER_H
8 #define STOPFILTER_H
9 
10 #include "TokenFilter.h"
11 
12 namespace Lucene
13 {
15  class LPPAPI StopFilter : public TokenFilter
16  {
17  public:
29  StopFilter(bool enablePositionIncrements, TokenStreamPtr input, HashSet<String> stopWords, bool ignoreCase = false);
30  StopFilter(bool enablePositionIncrements, TokenStreamPtr input, CharArraySetPtr stopWords, bool ignoreCase = false);
31 
32  virtual ~StopFilter();
33 
35 
36  protected:
39 
42 
43  public:
45  static HashSet<String> makeStopSet(Collection<String> stopWords);
46 
48  virtual bool incrementToken();
49 
52  static bool getEnablePositionIncrementsVersionDefault(LuceneVersion::Version matchVersion);
53 
55  bool getEnablePositionIncrements();
56 
64  void setEnablePositionIncrements(bool enable);
65  };
66 }
67 
68 #endif

clucene.sourceforge.net