CLucene - a full-featured, c++ search engine
API Documentation
00001 /*------------------------------------------------------------------------------ 00002 * Copyright (C) 2003-2006 Ben van Klinken and the CLucene Team 00003 * 00004 * Distributable under the terms of either the Apache License (Version 2.0) or 00005 * the GNU Lesser General Public License, as specified in the COPYING file. 00006 ------------------------------------------------------------------------------*/ 00007 #ifndef _lucene_index_SegmentMergeInfo_ 00008 #define _lucene_index_SegmentMergeInfo_ 00009 00010 #if defined(_LUCENE_PRAGMA_ONCE) 00011 # pragma once 00012 #endif 00013 00014 #include "SegmentTermEnum.h" 00015 #include "SegmentHeader.h" 00016 00017 CL_NS_DEF(index) 00018 class SegmentMergeInfo:LUCENE_BASE { 00019 int32_t* docMap; // maps around deleted docs 00020 TermPositions* postings; 00021 public: 00022 TermEnum* termEnum; 00023 Term* term; 00024 int32_t base; 00025 IndexReader* reader; 00026 00027 //Constructor 00028 SegmentMergeInfo(const int32_t b, TermEnum* te, IndexReader* r); 00029 00030 //Destructor 00031 ~SegmentMergeInfo(); 00032 00033 //Moves the current term of the enumeration termEnum to the next and term 00034 //points to this new current term 00035 bool next(); 00036 00037 //Closes the the resources 00038 void close(); 00039 00040 // maps around deleted docs 00041 int32_t* getDocMap(); 00042 00043 TermPositions* getPositions(); 00044 }; 00045 CL_NS_END 00046 #endif 00047