Question: DELIVERABLE Submit a single zipfile to the MyCourses HW4 dropbox. Homework MUST be submitted on time to receive full credit. Homework submitted to the late

 DELIVERABLE Submit a single zipfile to the MyCourses HW4 dropbox. HomeworkMUST be submitted on time to receive full credit. Homework submitted tothe "late" dropbox will receive a maximum grade of 80%. Homework not

DELIVERABLE Submit a single zipfile to the MyCourses HW4 dropbox. Homework MUST be submitted on time to receive full credit. Homework submitted to the "late" dropbox will receive a maximum grade of 80%. Homework not submitted to a dropbox will receive no credit. ASSIGNMENT Based on earlier course material, this assignment will enhance BankAccount to demonstrate how abstraction and encapsulation enable evolutionary software changes Start with the version of BankAccount.java in the Downloads for HW04 from the myCourses HW04 content area. Begin by incorporating a transaction (service) fee for every deposit and withdrawal. Supply a setTransFee mutator method for setting a fee charged for every transaction and modify the deposit and withdraw methods so that the fee is levied. Test the resulting class and check that the fee is computed correctly Before continuing, remove the changes made to the deposit and withdraw methods but keep the attribute and the mutator. Now make a more complex change. The bank will allow a fixed number of free transactions (deposits or withdrawals) every month, and charge for transactions exceeding the free allotment. The charge is not levied immediately but at the end of the month. Supply another mutator method called setNumFreeTrans ) that sets the ree transactions number. Declare, initialize, and increment a transaction count attribute. Increment this count for each transaction Supply a new, deductMonthlyCharge (), method to the BankAccount class called that deducts the monthly charge from the account balance, but only if the number of free transactions is exceeded, and then resets the transaction count. Hint Use the max method from the Math class Math.max (actual transaction count, free transaction count) Think about what the simple formula should be? Do NOT use an if statement. Design a test program that verifies that the fees are calculated correctly over several months

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!