File tree Expand file tree Collapse file tree
LessonsSamples/LessonsSamples/Lesson7 Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -5,12 +5,16 @@ namespace LessonsSamples.Lesson7.CohesionCoupling
55 public class PageXml
66 {
77 public CustomerXml Customer { get ; set ; }
8+
9+ //.... other properties that describe the XML format of a page w/ customer data
810 }
911
1012 public class CustomerXml
1113 {
1214 public string Name { get ; set ; }
1315 public List < AddressXml > Addresses { get ; set ; }
16+
17+ //.... other properties that describe the XML format of a customer
1418 }
1519
1620 public class AddressXml
Original file line number Diff line number Diff line change @@ -29,15 +29,13 @@ public decimal MonthlyInterest()
2929 return amount * interestRate / 100 ;
3030 }
3131
32- public virtual void MonthlyRenewal ( )
32+ public virtual void MonthlyRenewal ( Month currentMonth )
3333 {
3434 decimal interest = MonthlyInterest ( ) ;
35- decimal taxes = CalculateTaxesForMoth ( CurrentMonth ) ;
35+ decimal taxes = CalculateTaxesForMoth ( currentMonth ) ;
3636
3737 amount = amount + interest - taxes ;
3838 }
39-
40- public Month CurrentMonth { get ; set ; }
4139 }
4240
4341 class SavingsAccount : Account
@@ -96,10 +94,10 @@ public AutoLoanAccount(decimal interestRate) : base(interestRate)
9694 {
9795 }
9896
99- public override void MonthlyRenewal ( )
97+ public override void MonthlyRenewal ( Month currentMonth )
10098 {
10199 decimal interest = MonthlyInterest ( ) ;
102- decimal taxes = CalculateTaxesForMoth ( CurrentMonth ) ;
100+ decimal taxes = CalculateTaxesForMoth ( currentMonth ) ;
103101
104102 Amount = Amount - interest - taxes ;
105103 }
You can’t perform that action at this time.
0 commit comments