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

SegmentTermVector.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 SEGMENTTERMVECTOR_H
8 #define SEGMENTTERMVECTOR_H
9
10 #include "TermPositionVector.h"
11
12 namespace Lucene {
13
14 class SegmentTermVector : public TermPositionVector, public LuceneObject {
15 public:
16 SegmentTermVector(const String& field, Collection<String> terms, Collection<int32_t> termFreqs);
17 virtual ~SegmentTermVector();
18
19 LUCENE_CLASS(SegmentTermVector);
20
21 protected:
22 String field;
23 Collection<String> terms;
24 Collection<int32_t> termFreqs;
25
26 public:
28 virtual String getField();
29
30 virtual String toString();
31
33 virtual int32_t size();
34
36 virtual Collection<String> getTerms();
37
39 virtual Collection<int32_t> getTermFrequencies();
40
43 virtual int32_t indexOf(const String& term);
44
46 virtual Collection<int32_t> indexesOf(Collection<String> termNumbers, int32_t start, int32_t length);
47 };
48
49 }
50
51 #endif
TermPositionVector.h
Lucene::SegmentTermVector::terms
Collection< String > terms
Definition: SegmentTermVector.h:23
Lucene::SegmentTermVector::~SegmentTermVector
virtual ~SegmentTermVector()
Lucene::SegmentTermVector::size
virtual int32_t size()
Lucene::SegmentTermVector::indexOf
virtual int32_t indexOf(const String &term)
Return an index in the term numbers array returned from getTerms at which the term with the specified...
Lucene::SegmentTermVector::getField
virtual String getField()
Lucene::SegmentTermVector::toString
virtual String toString()
Returns a string representation of the object.
Lucene::SegmentTermVector::SegmentTermVector
SegmentTermVector(const String &field, Collection< String > terms, Collection< int32_t > termFreqs)
Lucene::SegmentTermVector::getTermFrequencies
virtual Collection< int32_t > getTermFrequencies()
Lucene::SegmentTermVector
Definition: SegmentTermVector.h:14
Lucene::SegmentTermVector::termFreqs
Collection< int32_t > termFreqs
Definition: SegmentTermVector.h:24
Lucene::LuceneObject
Base class for all Lucene classes.
Definition: LuceneObject.h:31
LUCENE_CLASS
#define LUCENE_CLASS(Name)
Definition: LuceneObject.h:24
Lucene
Definition: AbstractAllTermDocs.h:12
Lucene::SegmentTermVector::getTerms
virtual Collection< String > getTerms()
Lucene::Collection< String >
Lucene::SegmentTermVector::field
String field
Definition: SegmentTermVector.h:19
Lucene::TermPositionVector
Extends TermFreqVector to provide additional information about positions in which each of the terms i...
Definition: TermPositionVector.h:16
Lucene::SegmentTermVector::indexesOf
virtual Collection< int32_t > indexesOf(Collection< String > termNumbers, int32_t start, int32_t length)
Just like indexOf(int) but searches for a number of terms at the same time.

clucene.sourceforge.net