22 #ifndef TITANIC_TT_WORD_H 23 #define TITANIC_TT_WORD_H 25 #include "titanic/support/exe_resources.h" 26 #include "titanic/support/simple_file.h" 27 #include "titanic/true_talk/tt_string.h" 28 #include "titanic/true_talk/tt_synonym.h" 36 WC_UNKNOWN = 0, WC_ACTION = 1, WC_THING = 2, WC_ABSTRACT = 3,
37 WC_ARTICLE = 4, WC_CONJUNCTION = 5, WC_PRONOUN = 6,
38 WC_PREPOSITION = 7, WC_ADJECTIVE = 8, WC_ADVERB = 9
43 TTstringStatus _status;
52 bool testFileHandle(
SimpleFile *file)
const {
return true; }
53 bool testFileHandle(FileHandle resHandle)
const;
110 const char *c_str()
const {
return _text.
c_str(); }
111 operator const char *()
const {
return c_str(); }
138 bool isValid()
const {
return _status == SS_VALID; }
148 bool isClass(WordClass wordClass)
const {
return _wordClass == wordClass; }
160 virtual bool proc2(
int val)
const {
return false; }
161 virtual int proc3()
const {
return -1; }
162 virtual void proc4() {}
163 virtual void proc5() {}
178 virtual uint
getTag()
const {
return 0; }
180 virtual bool proc9(
int val)
const {
return false; }
181 virtual int proc10()
const {
return 0; }
182 virtual void proc11() {}
183 virtual bool proc12(
int val)
const {
return false; }
184 virtual int proc13()
const {
return 0; }
185 virtual bool proc14(
int val)
const {
return false; }
186 virtual int proc15()
const {
return -1; }
187 virtual bool proc16()
const {
return false; }
188 virtual bool proc17()
const {
return false; }
189 virtual bool proc18()
const {
return false; }
190 virtual bool comparePronounTo(
int val)
const {
return false; }
191 virtual int proc20()
const {
return 0; }
const char * c_str() const
Definition: tt_string.h:128
virtual FileHandle getSynFile() const
virtual uint getTag() const
Definition: tt_word.h:178
void appendNode(TTsynonym *node)
void setSyn(TTsynonym *synP)
Definition: tt_synonym.h:30
int load(SimpleFile *file, WordClass wordClass)
Definition: simple_file.h:49
virtual bool compareTagTo(uint tag) const
Definition: tt_word.h:173
virtual bool checkTag() const
Definition: tt_word.h:168
const TTstring getText()
Definition: tt_word.h:116
virtual void setSynFile(FileHandle file)
bool findSynByName(const TTstring &str, TTsynonym *dest, VocabMode mode) const
bool isValid() const
Definition: tt_word.h:138
TTstringStatus getChainStatus() const
virtual TTword * copy() const
uint readNumber(const char *str)
virtual bool checkSynFile(FileHandle file) const
bool hasSynonyms() const
Definition: tt_word.h:89
Definition: tt_string.h:45
TTstringStatus getStatus() const
Definition: tt_word.h:133
bool isClass(WordClass wordClass) const
Definition: tt_word.h:148
bool compareTo(TTstring *str) const
Definition: tt_word.h:126
virtual int save(SimpleFile *file) const
Definition: tt_word.h:212
bool compareTo(const char *str) const
int readSyn(SimpleFile *file)
int setSynStr(TTstring &str)