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

LogDocMergePolicy.h
Go to the documentation of this file.
1 // 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 LOGDOCMERGEPOLICY_H
8 #define LOGDOCMERGEPOLICY_H
9
10 #include "LogMergePolicy.h"
11
12 namespace Lucene {
13
16 class LPPAPI LogDocMergePolicy : public LogMergePolicy {
17 public:
18 LogDocMergePolicy(const IndexWriterPtr& writer);
19 virtual ~LogDocMergePolicy();
20
21 LUCENE_CLASS(LogDocMergePolicy);
22
23 public:
25 static const int32_t DEFAULT_MIN_MERGE_DOCS;
26
27 protected:
28 virtual int64_t size(const SegmentInfoPtr& info);
29
30 public:
36 void setMinMergeDocs(int32_t minMergeDocs);
37
39 int32_t getMinMergeDocs();
40 };
41
42 }
43
44 #endif
LogMergePolicy.h
LUCENE_CLASS
#define LUCENE_CLASS(Name)
Definition: LuceneObject.h:24
Lucene::LogDocMergePolicy
This is a LogMergePolicy that measures size of a segment as the number of documents (not taking delet...
Definition: LogDocMergePolicy.h:16
Lucene::LogDocMergePolicy::DEFAULT_MIN_MERGE_DOCS
static const int32_t DEFAULT_MIN_MERGE_DOCS
Default minimum segment size.
Definition: LogDocMergePolicy.h:21
Lucene::LogDocMergePolicy::LogDocMergePolicy
LogDocMergePolicy(const IndexWriterPtr &writer)
Lucene::LogDocMergePolicy::size
virtual int64_t size(const SegmentInfoPtr &info)
Lucene::LogDocMergePolicy::getMinMergeDocs
int32_t getMinMergeDocs()
Get the minimum size for a segment to remain un-merged.
Lucene::LogDocMergePolicy::~LogDocMergePolicy
virtual ~LogDocMergePolicy()
Lucene::LogDocMergePolicy::setMinMergeDocs
void setMinMergeDocs(int32_t minMergeDocs)
Sets the minimum size for the lowest level segments. Any segments below this size are considered to b...
Lucene::LogMergePolicy
This class implements a MergePolicy that tries to merge segments into levels of exponentially increas...
Definition: LogMergePolicy.h:24
Lucene
Definition: AbstractAllTermDocs.h:12
Lucene::SegmentInfoPtr
boost::shared_ptr< SegmentInfo > SegmentInfoPtr
Definition: LuceneTypes.h:208
Lucene::IndexWriterPtr
boost::shared_ptr< IndexWriter > IndexWriterPtr
Definition: LuceneTypes.h:160

clucene.sourceforge.net