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

- Main Page
- Related Pages
- Namespaces
- Data Structures
- Files

- File List
- Globals

PhrasePositions.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 PHRASEPOSITIONS_H
8 #define PHRASEPOSITIONS_H
9
10 #include "LuceneObject.h"
11
12 namespace Lucene {
13
15 class PhrasePositions : public LuceneObject {
16 public:
17 PhrasePositions(const TermPositionsPtr& t, int32_t o);
18 virtual ~PhrasePositions();
19
20 LUCENE_CLASS(PhrasePositions);
21
22 public:
23 int32_t doc; // current doc
24 int32_t position; // position in doc
25 int32_t count; // remaining pos in this doc
26 int32_t offset; // position in phrase
27 TermPositionsPtr tp; // stream of positions
28 PhrasePositionsPtr _next; // used to make lists
29 bool repeats; // there's other pp for same term (eg. query="1st word 2nd word"~1)
30
31 public:
32 bool next();
33 bool skipTo(int32_t target);
34 void firstPosition();
35 bool nextPosition();
36 };
37
38 }
39
40 #endif
Lucene::PhrasePositions::repeats
bool repeats
Definition: PhrasePositions.h:29
Lucene::PhrasePositions::_next
PhrasePositionsPtr _next
Definition: PhrasePositions.h:28
LuceneObject.h
Lucene::PhrasePositions::PhrasePositions
PhrasePositions(const TermPositionsPtr &t, int32_t o)
Lucene::PhrasePositions::tp
TermPositionsPtr tp
Definition: PhrasePositions.h:27
Lucene::LuceneObject
Base class for all Lucene classes.
Definition: LuceneObject.h:31
Lucene::TermPositionsPtr
boost::shared_ptr< TermPositions > TermPositionsPtr
Definition: LuceneTypes.h:243
Lucene::PhrasePositions::offset
int32_t offset
Definition: PhrasePositions.h:26
LUCENE_CLASS
#define LUCENE_CLASS(Name)
Definition: LuceneObject.h:24
Lucene
Definition: AbstractAllTermDocs.h:12
Lucene::PhrasePositions::~PhrasePositions
virtual ~PhrasePositions()
Lucene::PhrasePositions::skipTo
bool skipTo(int32_t target)
Lucene::PhrasePositions::count
int32_t count
Definition: PhrasePositions.h:25
Lucene::PhrasePositions::firstPosition
void firstPosition()
Lucene::PhrasePositionsPtr
boost::shared_ptr< PhrasePositions > PhrasePositionsPtr
Definition: LuceneTypes.h:410
Lucene::PhrasePositions::position
int32_t position
Definition: PhrasePositions.h:24
Lucene::PhrasePositions::next
bool next()
Lucene::PhrasePositions
Position of a term in a document that takes into account the term offset within the phrase...
Definition: PhrasePositions.h:15
Lucene::PhrasePositions::doc
int32_t doc
Definition: PhrasePositions.h:20
Lucene::PhrasePositions::nextPosition
bool nextPosition()

clucene.sourceforge.net