A Java OOP program that simulates a vending machine. The user puts in some amount of money and selects an item from a menu. If they have enough money, the user is told the change per coin and the inventory is updated. The items are stored, read and written from a text file. The program uses an MVC design pattern with a service layer and has unit tests for the DAO and service layer components. Big Decimal is used for monetary calculations and the program handles application-specific exceptions. The program also includes an audit DAO to log events and the time they occurred and uses Enums to represent the values of different coins. The application uses Spring dependency injection.
A Java OOP program that simulates a vending machine. The user puts in some amount of money and selects an item from a menu. If they have enough money, the user is told the change per coin and the inventory is updated. The items are stored, read and written from a text file. The program uses an MVC design pattern with a service layer and has unit tests for the DAO and service layer components. Big Decimal is used for monetary calculations and the program handles application-specific exceptions. The program also includes an audit DAO to log events and the time they occurred and uses Enums to represent the values of different coins. The application uses Spring dependency injection.