Esempio n. 1
0
        private bool _Load(int loanID, string path)
        {
            this.iLoanID = loanID;
            clsCSVTable tbl = new clsCSVTable(path);

            if (loanID < tbl.Length())
            {
                this.iPropertyID                      = Int32.Parse(tbl.Value(loanID, clsLoan.PropertyColumn));
                this.iTitleHolderEntityID             = Int32.Parse(tbl.Value(loanID, clsLoan.TitleHolderColumn));
                this.iCoBorrowerEntityID              = Int32.Parse(tbl.Value(loanID, clsLoan.CoBorrowerColumn));
                this.iAcquisitionTitleCompanyEntityID = Int32.Parse(tbl.Value(loanID, clsLoan.TitleCompanyColumn));
                this.iLenderEntityID                  = Int32.Parse(tbl.Value(loanID, clsLoan.LenderColumn));
                this.dtMaturity    = DateTime.Parse(tbl.Value(loanID, clsLoan.MaturityDateCoumn));
                this.dtOrigination = DateTime.Parse(tbl.Value(loanID, clsLoan.OGDateColumn));
                this.dRate         = Double.Parse(tbl.Value(loanID, clsLoan.RateColumn));
                this.dPenaltyRate  = Double.Parse(tbl.Value(loanID, clsLoan.PenaltyRateColumn));
                this.pProperty     = new clsProperty(this.iPropertyID);
                this._LoadCashflows();
                return(true);
            }
            else
            {
                return(false);
            }
        }
Esempio n. 2
0
 public clsLoan(int loanID)
 {
     if (loanID < 0)
     {
         this.iLoanID                          = loanID;
         this.iPropertyID                      = -1;
         this.iTitleHolderEntityID             = -1;
         this.iAcquisitionTitleCompanyEntityID = -1;
         this.iCoBorrowerEntityID              = -1;
         this.iLenderEntityID                  = -1;
         this.cfCashflows                      = new List <clsCashflow>();
         this.pProperty                        = new clsProperty("N/A", "N/A", "N/A", "NA", 0, "FundOps");
         this.dtMaturity                       = System.DateTime.MaxValue;
         this.dtOrigination                    = System.DateTime.MinValue;
         this.dRate        = 0D;
         this.dPenaltyRate = 0D;
     }
     else
     {
         this._Load(loanID);
     }
 }
Esempio n. 3
0
        public clsLoan(int propertyID, int titleHolderID, int coBorrowerID, int titleCoID, int lenderID,
                       DateTime orig, DateTime mature, double r, double pr, int loanID = -1)
        {
            if (loanID < 0)
            {
                this.iLoanID = this._NewLoanID();
            }
            else
            {
                this.iLoanID = loanID;
            }
            this.iPropertyID                      = propertyID;
            this.iTitleHolderEntityID             = titleHolderID;
            this.iCoBorrowerEntityID              = coBorrowerID;
            this.iAcquisitionTitleCompanyEntityID = titleCoID;
            this.iLenderEntityID                  = lenderID;
            this.dtMaturity = mature;

            this.dtOrigination = orig;
            this.dRate         = r;
            this.dPenaltyRate  = pr;
            this.pProperty     = new clsProperty(propertyID);
            this.cfCashflows   = new List <clsCashflow>();
        }