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

Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Data Fields
Lucene::OneMerge Class Reference

OneMerge provides the information necessary to perform an individual primitive merge operation, resulting in a single new segment. The merge spec includes the subset of segments to be merged as well as whether the new segment should use the compound file format. More...

`#include <MergePolicy.h>`

Inheritance diagram for Lucene::OneMerge:

## Public Member Functions

| OneMerge (const SegmentInfosPtr &segments, bool useCompoundFile)
virtual | ~OneMerge ()
virtual String | getClassName ()
boost::shared_ptr< OneMerge > | shared_from_this ()
void | setException (const LuceneException &error)
| Record that an exception occurred while executing this merge.
LuceneException | getException ()
| Retrieve previous exception set by `setException`.
void | abort ()
| Mark this merge as aborted. If this is called before the merge is committed then the merge will not be committed.
bool | isAborted ()
| Returns true if this merge was aborted.
void | checkAborted (const DirectoryPtr &dir)
String | segString (const DirectoryPtr &dir)
Public Member Functions inherited from Lucene::LuceneObject
virtual | ~LuceneObject ()
virtual void | initialize ()
| Called directly after instantiation to create objects that depend on this object being fully constructed.
virtual LuceneObjectPtr | clone (const LuceneObjectPtr &other=LuceneObjectPtr())
| Return clone of this object.
virtual int32_t | hashCode ()
| Return hash code for this object.
virtual bool | equals (const LuceneObjectPtr &other)
| Return whether two objects are equal.
virtual int32_t | compareTo (const LuceneObjectPtr &other)
| Compare two objects.
virtual String | toString ()
| Returns a string representation of the object.
Public Member Functions inherited from Lucene::LuceneSync
virtual | ~LuceneSync ()
virtual SynchronizePtr | getSync ()
| Return this object synchronize lock.
virtual LuceneSignalPtr | getSignal ()
| Return this object signal.
virtual void | lock (int32_t timeout=0)
| Lock this object using an optional timeout.
virtual void | unlock ()
| Unlock this object.
virtual bool | holdsLock ()
| Returns true if this object is currently locked by current thread.
virtual void | wait (int32_t timeout=0)
| Wait for signal using an optional timeout.
virtual void | notifyAll ()
| Notify all threads waiting for signal.

## Static Public Member Functions

static String | _getClassName ()

## Data Fields

SegmentInfoPtr | info
bool | mergeDocStores
bool | optimize
bool | registerDone
int64_t | mergeGen
bool | isExternal
int32_t | maxNumSegmentsOptimize
Collection< SegmentReaderPtr > | readers
Collection< SegmentReaderPtr > | readersClone
SegmentInfosPtr | segments
bool | useCompoundFile
bool | aborted
LuceneException | error

## Additional Inherited Members

Protected Member Functions inherited from Lucene::LuceneObject
| LuceneObject ()
Protected Attributes inherited from Lucene::LuceneSync
SynchronizePtr | objectLock
LuceneSignalPtr | objectSignal

## Detailed Description

OneMerge provides the information necessary to perform an individual primitive merge operation, resulting in a single new segment. The merge spec includes the subset of segments to be merged as well as whether the new segment should use the compound file format.

## Constructor & Destructor Documentation

## ◆ OneMerge()

Lucene::OneMerge::OneMerge | ( | const SegmentInfosPtr & | segments,
|  | bool | useCompoundFile
| ) |  |

## ◆ ~OneMerge()

virtual Lucene::OneMerge::~OneMerge | ( |  | ) |

virtual

## Member Function Documentation

## ◆ _getClassName()

static String Lucene::OneMerge::_getClassName | ( |  | ) |

inline static

## ◆ abort()

void Lucene::OneMerge::abort | ( |  | ) |

Mark this merge as aborted. If this is called before the merge is committed then the merge will not be committed.

## ◆ checkAborted()

void Lucene::OneMerge::checkAborted | ( | const DirectoryPtr & | dir | ) |

## ◆ getClassName()

virtual String Lucene::OneMerge::getClassName | ( |  | ) |

inline virtual

## ◆ getException()

LuceneException Lucene::OneMerge::getException | ( |  | ) |

Retrieve previous exception set by `setException`.

## ◆ isAborted()

bool Lucene::OneMerge::isAborted | ( |  | ) |

Returns true if this merge was aborted.

## ◆ segString()

String Lucene::OneMerge::segString | ( | const DirectoryPtr & | dir | ) |

## ◆ setException()

void Lucene::OneMerge::setException | ( | const LuceneException & | error | ) |

Record that an exception occurred while executing this merge.

## ◆ shared_from_this()

boost::shared_ptr< OneMerge > Lucene::OneMerge::shared_from_this | ( |  | ) |

inline

## Field Documentation

## ◆ aborted

bool Lucene::OneMerge::aborted

## ◆ error

LuceneException Lucene::OneMerge::error

## ◆ info

SegmentInfoPtr Lucene::OneMerge::info

## ◆ isExternal

bool Lucene::OneMerge::isExternal

## ◆ maxNumSegmentsOptimize

int32_t Lucene::OneMerge::maxNumSegmentsOptimize

## ◆ mergeDocStores

bool Lucene::OneMerge::mergeDocStores

## ◆ mergeGen

int64_t Lucene::OneMerge::mergeGen

## ◆ optimize

bool Lucene::OneMerge::optimize

## ◆ readers

Collection<SegmentReaderPtr> Lucene::OneMerge::readers

## ◆ readersClone

Collection<SegmentReaderPtr> Lucene::OneMerge::readersClone

## ◆ registerDone

bool Lucene::OneMerge::registerDone

## ◆ segments

SegmentInfosPtr Lucene::OneMerge::segments

## ◆ useCompoundFile

bool Lucene::OneMerge::useCompoundFile

The documentation for this class was generated from the following file:

- MergePolicy.h

clucene.sourceforge.net