Java Program for ATM machines

Description

Write Java Program for ATM machines

Two Banks (Bank A & B)

Hard Code, 2 customers for Bank A with $50 in the account (each customer have their own cash cards)

Hard Code, 3 customers for Bank B with $50 in the account (each customer have their own cash cards)

Cash Cards come with expiration date and withdraw transaction only.

Design 2 ATM machines (ATM_A1 & ATM_A2) for Bank A

Design 2 ATM machines (ATM_B1 & ATM_B2) for Bank B

Each ATM machine take their own bank’s cash card’s account number, password, and expiration date.

Requirements are:

Bank A only work with ATM_A1 & ATM_A2

Bank B only work with ATM_B1 & ATM_B2

When accounts are verified, customers can withdraw money on their cash card’s balance.

NOTE: error messages should show if the requirements are not met. For example, Bank A cash card try

to withdraw money from Bank B ATM machines vice versa. Customers withdraw more than account

balance. (see sample output below).

At least 4 or 5 different classes (for example, ATMSystem.java, ATM.java, Bank.java, CashCard.java,

Customer.java, BankDatabase.java, or …) that has is-a (inheritance classes) or has-a relationship.

Javadoc each class such that /**@param*/ /**@return */

If possible, include use cases or UML

Sample Output

State of 2 Banks //Hard code started

Set accounts $50 preloaded.

BankA (2 customers)

Customer with Cash Card (bankid: A, account number 11, expires on 12/12/16,

password aaa

Customer with Cash Card (bankid: A, account number 12, expires on 05/01/17,

password bbb

BankB (three customers)

Customer with Cash Card (bankid: B, account number 111), expires on 11/11/11,

password ccc

Customer with Cash Card (bankid: B, account number 112), expires on 12/12/12,

password ddd

Customer with Cash Card (bankid: B, account number 113), expires on 12/12/17,

password eee

State of 4 ATMs (2 for each Bank)

ATM1_A: (ATM1 from BankA)

The maximum amount of cash a card can widthraw per day: $60

ATM2_A: (ATM1 from BankA)

The maximum amount of cash a card can widthraw per day: $60

ATM1_B: (ATM1 from BankB)

The maximum amount of cash a card can widthraw per day: $60

ATM2_B: (ATM1 from BankB)

The maximum amount of cash a card can widthraw per day: $60

//Hard code ended

//User input started

% Enter your choice of ATM

ATM1_A

% Enter your card

11

“This card is expired please enter different card”

/*if enter 12, then OK because not expired & correct card */

% Enter your card

112

“This card is not supported by this ATM Enter your card again”

% 12

“The card is accepted”

% Please enter your password

aaa

“This is a wrong password. Enter correct password”

% Please enter your password

bbb

“Authorization is accepted”

% Please enter withdraw amount.

100

“This amount exceeds the max can withdraw per transaction. Please enter the

amount or quit”

% Please enter withdraw amount.

25

“$25 is withdrawn from your account. The remaining balance of this account

is $25. If you have more withdraw transactions, enter the amount or quit”

% Please enter withdraw amount.

55

“This amount exceeds the current balance. Enter another amount or quit.

% 15

“$25 is withdrawn from your account. The remaining balance of this account

is $0. If you have more transactions, enter the amount or quit.

quit

//users input ended

Calculate the price of your order

Simple Order Process

Fill in the Order Form

Share all the assignment information. Including the instructions, provided reading materials, grading rubric, number of pages, the required formatting, deadline, and your academic level. Provide any information and announcements shared by the professor. Choose your preferred writer if you have one.

Get Your Order Assigned

Once we receive your order form, we will select the best writer from our pool of experts to fit your assignment.

Share More Data if Needed

You will receive a confirmation email when a writer has been assigned your task. The writer may contact you if they need any additional information or clarifications regarding your task

Let Our Essay Writer Do Their Job

Once you entrust us with your academic task, our skilled writers embark on creating your paper entirely from the ground up. Through rigorous research and unwavering commitment to your guidelines, our experts meticulously craft every aspect of your paper. Our process ensures that your essay is not only original but also aligned with your specific requirements, making certain that the final piece surpasses your expectations.

Quality Checks and Proofreading

Upon the completion of your paper, it undergoes a meticulous review by our dedicated Quality and Proofreading department. This crucial step ensures not only the originality of the content but also its alignment with the highest academic standards. Our seasoned experts conduct thorough checks, meticulously examining every facet of your paper, including grammar, structure, coherence, and proper citation. This comprehensive review process guarantees that the final product you receive not only meets our stringent quality benchmarks but also reflects your dedication to academic excellence.

Review and Download the Final Draft

If you find that any part of the paper does not meet the initial instructions, send it back to us with your feedback, and we will make the necessary adjustments.