Main Page | Modules | Namespace List | Compound List | File List | Compound Members | File Members | Related Pages

DetLemma.h

Go to the documentation of this file.
00001 
00002 #ifndef DETLEMMA_H
00003 #define DETLEMMA_H
00004 #pragma warning(disable:4786)
00005 #include <string>
00006 #include <stack>
00007 #include <map>
00008 #include <vector>
00009 #include "UMString.h"
00010 #include "Flexform.h"
00011 #include "XMLReader.h"
00012 #include "JXDictionary.h"
00016 struct result_lemma{
00017 
00018  string lemma;  
00019  string entry_dt;  
00020  string entry_engl;  
00021  string lemma_form;  
00022  string lemma_vflexkl;   
00023   string lemma_kanji;  
00024    string lemma_hira;   
00027 };  
00028 class HypoLemma{
00029         vector<JVerbalFlexion*> m_jvf_history;              
00030         typedef vector<JVerbalFlexion*>::iterator IT;   
00032         string m_hira_rest;        
00033         int m_cur_level;         
00034         string m_components;         
00035         string m_hira_check;                            
00037     public:
00038                 
00039                 HypoLemma(JVerbalFlexion*, string&, string&);
00040                 ~HypoLemma();
00041                 bool insertElement(JVerbalFlexion*);
00042                 bool insertElement(JVerbalFlexion*, string&, string&);
00043                 bool deleteElement(UINT pos);
00046                 string GetHiraRest(){ return m_hira_rest;}; 
00049                 string GetHiraCheck(){ return m_hira_check;};
00052                 string GetComponents(){ return m_components;};
00054                 void clearHistory(){ m_jvf_history.clear();};
00055                 string GetCompString();
00058                 void SetHiraRest(string& rest){  m_hira_rest=rest;};
00061                  void SetHiraCheck(string& check){ m_hira_check=check;};
00064                 JVerbalFlexion* GetLastJVF(){ return m_jvf_history.back();};
00065                 
00066 
00067 };
00068 
00069 
00070 class DetLemma{
00071 
00072 private:                                 
00073          vector<FlexLevel*> m_flexlevel;          
00074          typedef vector <FlexLevel*> ::iterator IT;
00076          vector<HypoLemma> m_hypothesen;                                  
00077         typedef vector<HypoLemma>::iterator HIT; 
00079         int m_number_of_levels;                     
00080         int m_number_of_entries;        
00081         int m_flexmaxlength;              
00083         int m_level_counter[MAXFLEX];           
00084         int getHighestLevel(char*);                   
00086         list<result_lemma> m_result_list;   
00087         string m_cur_reqform;                 
00088         string m_cur_reqflexart;            
00090         JVerbalFlexion* hypo;            
00093 public:
00094         DetLemma();
00095         ~DetLemma();
00096         bool fillFlex(char*);
00097         bool detLemma(string&, JXDictionary*, list<result_lemma>&,  FILE*);
00098         bool confirmLemma(string&, string& , JXDictionary*, result_lemma&);
00099         bool findInLevel(string&, UINT);
00100         bool insertFlextoLevel(FlexLevel*, int); 
00101         void HypoPrint();
00102         bool insertPossibleHypos(JVerbalFlexion* jvf, UMString hirastr, int j);
00103 };
00104 
00105 
00106 #endif

Generated on Mon Aug 18 19:27:09 2003 for LeJa by doxygen 1.3.3