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


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

clucene.sourceforge.net