This is the simple application which simulate how the ATM system works.
- JDK 1.8
Prepare the CSV file for storing the Account Data by following format below:
The delimiter is ;
account_name;pin;balance;account_number
Or you can find the example file inside Project Directory.
- Clone the repository here.
- Go to the project's directory:
mini_atm_simulator
- Compile all the *java files by running this command below:
javac -d bin src\com\mitrais\atm\*.java src\com\mitrais\atm\model\*.java src\com\mitrais\atm\repository\*.java src\com\mitrais\atm\screen\*.java src\com\mitrais\atm\service\*.java src\com\mitrais\atm\validation\*.java
- Create manifest file by running:
echo Main-Class: com.mitrais.atm.Main > MANIFEST.mf
- Create jar file by running:
jar cfvm atm.jar MANIFEST.mf -C bin/ .
There are 2 ways to run this application:
-
Without Data Source File:
Type command:
java -jar atm.jar
on your Terminal.The Account Data will be loaded from default data below:
Name Account Number PIN Balance John Doe 112233 012108 $100 Jane Doe 112244 932012 $30 -
With Data Source File:
Type command:
java -jar atm.jar <data_source_filepath>
on your Terminal.Example
java -jar atm.jar D:\Users\blabla\data.csv