home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / dokpr1.zip / lomos / loandet.h < prev    next >
Text File  |  1995-11-09  |  2KB  |  80 lines

  1.  
  2. #include "mesamod.h"
  3. #include "interest.h"
  4. #include "change.h"
  5.  
  6. #define LO_REDISPLAY       WM_USER+20
  7. #define LO_CHANGEDSIZE     WM_USER+21
  8. #define LO_FORMATSCHANGED  WM_USER+22
  9. #define LO_CONTENTSCHANGED WM_USER+23
  10. #define LO_RESETVIEW       WM_USER+24
  11.  
  12. // the LOInterest class allows the Loan to know when something has changed
  13. // during the incell editing of the sheet view.  Thus, it can update it's display.
  14. // Each method just send one of the above messages to the window.
  15. class LOInterest:public MInterest
  16. {
  17.     public:
  18.     LOInterest(HWND hw);
  19.     ~LOInterest();
  20.  
  21.     // this method is thread-safe
  22.     virtual void redisplay(MChange *);
  23.     virtual void changedSize(MChange *);
  24.     virtual void formatsChanged(MChange *);
  25.     virtual void contentsChanged(MChange *);
  26.      virtual void resetView(MChange *);
  27.  
  28.     private:
  29.     HWND theWin;
  30. };
  31.  
  32.  
  33. // the purchase order wrapper for the model
  34. class Loan {
  35. public:
  36.    Loan(HWND hwnd);
  37.    Loan(char * filename,HWND hwnd);
  38.  
  39.    ~Loan();
  40.  
  41. char *LoanID();
  42. char *AppDate();
  43. char *RepID();
  44. char *Name();
  45. char *SSNo();
  46. char *Type();
  47. char *Amount();
  48. char *Rate();
  49. char *StDate();
  50. char *Duration();
  51. char *Periodicity();
  52.  
  53. void setLoanID(char * str);
  54. void setAppDate(char *str);
  55. void setRepID(char *str);
  56. void setName(char *str);
  57. void setSSNo(char *str);
  58. void setType(char *str);
  59. void setAmount(char *str);
  60. void setRate(char *str);
  61. void setStDate(char *str);
  62. void setDuration(char *str);
  63. void setPeriodicity(char *str);
  64. void setPeriods();
  65.  
  66. char *fileName();
  67. void setFileName(char * name);
  68. void save();
  69.  
  70. void displaySheetView(HWND hw);
  71. int isInSheetView() {return inSheetView; };
  72.  
  73. private:
  74.     MMesaModel *theModel;
  75.     MAddress currentEnum;
  76.     LOInterest * loint;
  77.     int inSheetView;
  78. };
  79.  
  80.