Question: The prescriptions provided below direct you how to implement the codes in the two classes Bank and Account. Account class: 1 . Implement the deposit
The prescriptions provided below direct you how to implement the codes in the two classes Bank and Account.
Account class:
Implement the deposit method to make a deposit of the amount passed and update the balance. The method signature or declaration is given as: @Override public void depositdouble amount TODO Autogenerated method stub
Implement the withdraw method to make a withdrawal of the amount passed from the account and update the balance. The method signature or declaration is given below as: @Override public void withdrawdouble amount TODO Autogenerated method stub
Implement the showBalance method to just print out and display the balance in the account. The method signature or declaration is given below as: @Override public void showBalance TODO Autogenerated method stub
Implement the retrieveBalance method to return the balance currently active in the account. The method signature or declaration is given below as: @Override public double retrieveBalace TODO Autogenerated method stub return ;
Implement the applyInterest method to calculate the interest on the balance based on the interest rate and then update the balance with the interest. Note: any interest awarded is added to the balance. The method signature or declaration is given below as: @Override public void applyInterest TODO Autogenerated method stub
After you have completed the implementation of the class Account, shift your focus to the methods in Bank class.
Bank class:
The addAccount method is already implemented for you, therefore, you dont have to do anything to this method. The method declaration and its body or definition is shown below. @Override public void addAccountAccount account TODO Autogenerated method stub acctList.addaccount;
Implement the removeAccount method to remove an account from the account list of the system. The account passed and the account in the system list must have some matching accomplished before removing the matched account. This has to be done through account number as matching criteria.
The List data structure removes data based on the index of the item. The method signature or declaration is given below as: @Override public void removeAccountAccount account TODO Autogenerated method stub
Implement the showAccounts method which displays all the accounts from the system list in more preferable and presentable format. The printout should show the list of account details with opened Date, residential address and even account type. The method signature or declaration is: @Override public void showAccounts TODO Autogenerated method stub
Implement the showAccountDetails method which searches for a particular account by account number as criteria from the system list, then once found, prints out the list of account details with opened Date, residential address and even account type. The method signature or declaration is: @Override public void showAccountDetailsint accountNumber TODO Autogenerated method stub
Implement the searchAccount method which searches for a particular account by account number as criteria from the system list, then once found, the method returns the account. If the account is not found, then the method returns null as the last option, otherwise, the method will crash. The method signature or declaration is:
@Override public Account searchAccountint accountNumber TODO Autogenerated method stub return null;
Implement the retrieveAccountList method which returns the system list of accounts to retrieve accounts data at application level. This method should not return any null pointer. The method signature or declaration is: @Override public List retrieveAccountList TODO Autogenerated method stub return null;
Implement the LoadAccountList method which uses the list of accounts passed through the parameter, to populate the current classes system list by adding each account of parameter to the system list. The method signature or declaration is:
method to be used to load bank account data from Databank public void LoadAccountListList accountList
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
