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

DefaultSkipListReader.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 DEFAULTSKIPLISTREADER_H
8 #define DEFAULTSKIPLISTREADER_H
9
10 #include "MultiLevelSkipListReader.h"
11
12 namespace Lucene {
13
15 class DefaultSkipListReader : public MultiLevelSkipListReader {
16 public:
17 DefaultSkipListReader(const IndexInputPtr& skipStream, int32_t maxSkipLevels, int32_t skipInterval);
18 virtual ~DefaultSkipListReader();
19
20 LUCENE_CLASS(DefaultSkipListReader);
21
22 protected:
23 bool currentFieldStoresPayloads;
24 Collection<int64_t> freqPointer;
25 Collection<int64_t> proxPointer;
26 Collection<int32_t> payloadLength;
27
28 int64_t lastFreqPointer;
29 int64_t lastProxPointer;
30 int32_t lastPayloadLength;
31
32 public:
33 void init(int64_t skipPointer, int64_t freqBasePointer, int64_t proxBasePointer, int32_t df, bool storesPayloads);
34
37 int64_t getFreqPointer();
38
41 int64_t getProxPointer();
42
45 int32_t getPayloadLength();
46
47 protected:
49 virtual void seekChild(int32_t level);
50
52 virtual void setLastSkipData(int32_t level);
53
55 virtual int32_t readSkipData(int32_t level, const IndexInputPtr& skipStream);
56 };
57
58 }
59
60 #endif
Lucene::DefaultSkipListReader::setLastSkipData
virtual void setLastSkipData(int32_t level)
Copies the values of the last read skip entry on this level.
Lucene::DefaultSkipListReader::proxPointer
Collection< int64_t > proxPointer
Definition: DefaultSkipListReader.h:25
Lucene::DefaultSkipListReader::getFreqPointer
int64_t getFreqPointer()
Returns the freq pointer of the doc to which the last call of MultiLevelSkipListReader#skipTo(int) ha...
MultiLevelSkipListReader.h
Lucene::MultiLevelSkipListReader::skipInterval
Collection< int32_t > skipInterval
Definition: MultiLevelSkipListReader.h:45
Lucene::DefaultSkipListReader::lastProxPointer
int64_t lastProxPointer
Definition: DefaultSkipListReader.h:29
Lucene::DefaultSkipListReader::currentFieldStoresPayloads
bool currentFieldStoresPayloads
Definition: DefaultSkipListReader.h:20
Lucene::DefaultSkipListReader::~DefaultSkipListReader
virtual ~DefaultSkipListReader()
Lucene::DefaultSkipListReader
Implements the skip list reader for the default posting list format that stores positions and payload...
Definition: DefaultSkipListReader.h:15
Lucene::DefaultSkipListReader::DefaultSkipListReader
DefaultSkipListReader(const IndexInputPtr &skipStream, int32_t maxSkipLevels, int32_t skipInterval)
Lucene::DefaultSkipListReader::getPayloadLength
int32_t getPayloadLength()
Returns the payload length of the payload stored just before the doc to which the last call of MultiL...
Lucene::MultiLevelSkipListReader::skipStream
Collection< IndexInputPtr > skipStream
Definition: MultiLevelSkipListReader.h:43
Lucene::DefaultSkipListReader::payloadLength
Collection< int32_t > payloadLength
Definition: DefaultSkipListReader.h:26
Lucene::DefaultSkipListReader::lastFreqPointer
int64_t lastFreqPointer
Definition: DefaultSkipListReader.h:28
Lucene::MultiLevelSkipListReader
This abstract class reads skip lists with multiple levels.
Definition: MultiLevelSkipListReader.h:20
Lucene::IndexInputPtr
boost::shared_ptr< IndexInput > IndexInputPtr
Definition: LuceneTypes.h:493
Lucene::DefaultSkipListReader::getProxPointer
int64_t getProxPointer()
Returns the prox pointer of the doc to which the last call of MultiLevelSkipListReader#skipTo(int) ha...
Lucene::DefaultSkipListReader::init
void init(int64_t skipPointer, int64_t freqBasePointer, int64_t proxBasePointer, int32_t df, bool storesPayloads)
LUCENE_CLASS
#define LUCENE_CLASS(Name)
Definition: LuceneObject.h:24
Lucene
Definition: AbstractAllTermDocs.h:12
Lucene::MultiLevelSkipListReader::skipPointer
Collection< int64_t > skipPointer
Definition: MultiLevelSkipListReader.h:44
Lucene::DefaultSkipListReader::freqPointer
Collection< int64_t > freqPointer
Definition: DefaultSkipListReader.h:24
Lucene::DefaultSkipListReader::lastPayloadLength
int32_t lastPayloadLength
Definition: DefaultSkipListReader.h:30
Lucene::Collection< int64_t >
Lucene::DefaultSkipListReader::seekChild
virtual void seekChild(int32_t level)
Seeks the skip entry on the given level.
Lucene::DefaultSkipListReader::readSkipData
virtual int32_t readSkipData(int32_t level, const IndexInputPtr &skipStream)
Subclasses must implement the actual skip data encoding in this method.

clucene.sourceforge.net