Lucene++ - a full-featured, c++ search engine
API Documentation
Main Page
Related Pages
Namespaces
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Pages
include
CachingWrapperFilter.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 CACHINGWRAPPERFILTER_H
8
#define CACHINGWRAPPERFILTER_H
9
10
#include "
Filter.h
"
11
12
namespace
Lucene
13
{
16
class
LPPAPI
CachingWrapperFilter
:
public
Filter
17
{
18
public
:
31
enum
DeletesMode
{ DELETES_IGNORE, DELETES_RECACHE, DELETES_DYNAMIC };
32
37
CachingWrapperFilter
(
FilterPtr
filter, DeletesMode deletesMode = DELETES_IGNORE);
38
39
virtual
~
CachingWrapperFilter
();
40
41
LUCENE_CLASS
(
CachingWrapperFilter
);
42
43
INTERNAL:
44
FilterPtr
filter;
45
46
// for testing
47
int32_t
hitCount
;
48
int32_t
missCount
;
49
50
protected
:
52
FilterCachePtr
cache
;
53
58
DocIdSetPtr
docIdSetToCache(
DocIdSetPtr
docIdSet,
IndexReaderPtr
reader);
59
60
public
:
61
virtual
DocIdSetPtr
getDocIdSet(
IndexReaderPtr
reader);
62
63
virtual
String toString();
64
virtual
bool
equals(
LuceneObjectPtr
other);
65
virtual
int32_t hashCode();
66
};
67
}
68
69
#endif
clucene.sourceforge.net