Natural Language Processing  0.1.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Pages
word.h
1 
8 #ifndef WORD_H
9 #define WORD_H
10 
11 #include "../Tokenizer/token.h"
12 #include "../Tokenizer/stokenize.h"
13 #include "set"
14 #include "../../CONFIG/config.h"
15 
16 using namespace std;
17 
18 namespace NLP
19 {
20 
21 class Word : public Token
22 {
23  private:
24  set<WordType> mTypes;
25  set<string> mDefinitions;
26 
27  public:
28  Word();
29  Word(const Token& other,
30  set<WordType> tags,
31  set<string> defs = set<string>()
32  );
33  Word(const Word& other);
34  Word& operator = (const Word& newToken);
35  ~Word();
36  string getName() const;
37  set<WordType> getTypes() const;
38  string getRawtypes() const;
39  set<string> getDefinitions() const;
40 
41  friend ostream& operator << (ostream& outs, const Word& w)
42  {
43  outs << w.getName();
44  return outs;
45  }
46 
47 }; /* ----- end of class Word ----- */
48 
49 } /* NLP */
50 
51 #endif /* !WORD_H */
52 
Definition: word.h:21
Definition: token.h:42