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

Loading...
Searching...
No Matches
OpenBitSetIterator.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 OPENBITSETITERATOR_H
8#define OPENBITSETITERATOR_H
9
10#include "DocIdSetIterator.h"
11
12 namespace Lucene {
13
17 class LPPAPI OpenBitSetIterator : public DocIdSetIterator {
18 public:
19 OpenBitSetIterator(const OpenBitSetPtr& bitSet);
20 OpenBitSetIterator(LongArray bits, int32_t numWords);
21 virtual ~OpenBitSetIterator();
22
23 LUCENE_CLASS(OpenBitSetIterator);
24
25 protected:
26 LongArray arr;
27 int32_t words;
28 int32_t i;
29 int64_t word;
30 int32_t wordShift;
31 int32_t indexArray;
32 int32_t curDocId;
33
38 static const int32_t bitlist[];
39
40 public:
41 virtual int32_t nextDoc();
42 virtual int32_t advance(int32_t target);
43 virtual int32_t docID();
44
45 protected:
47 void shift();
48};
49
50}
51
52#endif
DocIdSetIterator.h
LUCENE_CLASS
#define LUCENE_CLASS(Name)
Definition LuceneObject.h:24
Lucene::DocIdSetIterator
This abstract class defines methods to iterate over a set of non-decreasing doc ids....
Definition DocIdSetIterator.h:17
Lucene::OpenBitSetIterator::word
int64_t word
Definition OpenBitSetIterator.h:29
Lucene::OpenBitSetIterator::arr
LongArray arr
Definition OpenBitSetIterator.h:26
Lucene::OpenBitSetIterator::docID
virtual int32_t docID()
Returns the following:
Lucene::OpenBitSetIterator::i
int32_t i
Definition OpenBitSetIterator.h:28
Lucene::OpenBitSetIterator::wordShift
int32_t wordShift
Definition OpenBitSetIterator.h:30
Lucene::OpenBitSetIterator::words
int32_t words
Definition OpenBitSetIterator.h:27
Lucene::OpenBitSetIterator::OpenBitSetIterator
OpenBitSetIterator(const OpenBitSetPtr &bitSet)
Lucene::OpenBitSetIterator::shift
void shift()
64 bit shifts
Lucene::OpenBitSetIterator::~OpenBitSetIterator
virtual ~OpenBitSetIterator()
Lucene::OpenBitSetIterator::advance
virtual int32_t advance(int32_t target)
Advances to the first beyond the current whose document number is greater than or equal to target....
Lucene::OpenBitSetIterator::nextDoc
virtual int32_t nextDoc()
Advances to the next document in the set and returns the doc it is currently on, or NO_MORE_DOCS if t...
Lucene::OpenBitSetIterator::curDocId
int32_t curDocId
Definition OpenBitSetIterator.h:32
Lucene::OpenBitSetIterator::indexArray
int32_t indexArray
Definition OpenBitSetIterator.h:31
Lucene::OpenBitSetIterator::bitlist
static const int32_t bitlist[]
The General Idea: instead of having an array per byte that has the offsets of the next set bit,...
Definition OpenBitSetIterator.h:38
Lucene::OpenBitSetIterator::OpenBitSetIterator
OpenBitSetIterator(LongArray bits, int32_t numWords)
Lucene
Definition AbstractAllTermDocs.h:12
Lucene::OpenBitSetPtr
boost::shared_ptr< OpenBitSet > OpenBitSetPtr
Definition LuceneTypes.h:543

clucene.sourceforge.net