ModErn Text Analysis
META Enumerates Textual Applications
multi_analyzer.h
Go to the documentation of this file.
1 
10 #ifndef META_MULTI_ANALYZER_
11 #define META_MULTI_ANALYZER_
12 
13 #include <vector>
14 #include <memory>
15 
16 #include "analyzers/analyzer.h"
17 #include "util/clonable.h"
18 
19 namespace meta
20 {
21 namespace analyzers
22 {
23 
32 class multi_analyzer : public util::clonable<analyzer, multi_analyzer>
33 {
34  public:
39  multi_analyzer(std::vector<std::unique_ptr<analyzer>>&& toks);
40 
45  multi_analyzer(const multi_analyzer& other);
46 
51  virtual void tokenize(corpus::document& doc) override;
52 
53  private:
55  std::vector<std::unique_ptr<analyzer>> analyzers_;
56 };
57 }
58 }
59 
60 #endif
The multi_analyzer class contains more than one analyzer.
Definition: multi_analyzer.h:32
virtual void tokenize(corpus::document &doc) override
Tokenizes a file into a document.
Definition: multi_analyzer.cpp:24
Template class to facilitate polymorphic cloning.
Definition: clonable.h:28
Represents an indexable document.
Definition: document.h:31
The ModErn Text Analysis toolkit is a suite of natural language processing, classification, information retreival, data mining, and other applications of text processing.
Definition: analyzer.h:24
multi_analyzer(std::vector< std::unique_ptr< analyzer >> &&toks)
Constructs a multi_analyzer from a vector of other analyzers.
Definition: multi_analyzer.cpp:12
std::vector< std::unique_ptr< analyzer > > analyzers_
Holds all the analyzers in this multi_analyzer.
Definition: multi_analyzer.h:55