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

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

- File List
- Globals

All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
SortedTermVectorMapper.h
Go to the documentation of this file.
1 // Copyright (c) 2009-2011 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 SORTEDTERMVECTORMAPPER_H
8 #define SORTEDTERMVECTORMAPPER_H
9
10 #include <boost/function.hpp>
11 #include "TermVectorMapper.h"
12
13 namespace Lucene
14 {
22 class LPPAPI SortedTermVectorMapper : public TermVectorMapper
23 {
24 public:
26 SortedTermVectorMapper(TermVectorEntryComparator comparator);
27
28 SortedTermVectorMapper(bool ignoringPositions, bool ignoringOffsets, TermVectorEntryComparator comparator);
29
30 virtual ~SortedTermVectorMapper();
31
32 LUCENE_CLASS(SortedTermVectorMapper);
33
34 protected:
35 Collection<TermVectorEntryPtr> currentSet;
36 MapStringTermVectorEntry termToTVE;
37 bool storeOffsets;
38 bool storePositions;
39 TermVectorEntryComparator comparator;
40
41 public:
42 static const wchar_t* ALL;
43
44 public:
46 virtual void map(const String& term, int32_t frequency, Collection<TermVectorOffsetInfoPtr> offsets, Collection<int32_t> positions);
47
49 virtual void setExpectations(const String& field, int32_t numTerms, bool storeOffsets, bool storePositions);
50
57 Collection<TermVectorEntryPtr> getTermVectorEntrySet();
58 };
59 }
60
61 #endif

clucene.sourceforge.net