This is a Java-based application designed to assist with restaurant menu management. With simple CRUD features, the application allows users to:
- Add Menu Items:
- Regular Menu (code, name, price).
- Special Menu (with additional discount).
- View All Menu Items:
- Display a list of regular and special menus in an organized format, including discount details for special menus.
- Delete Menu Items:
- Remove menu items using their unique code.
This project leverages Object-Oriented Programming (OOP) concepts such as abstraction, polymorphism, and interfaces.
- Abstraction & Polymorphism
- Utilizes the abstract class
MenuItem
to model generic menu items. - Implements polymorphism to handle specific details for regular and special menus.
- Utilizes the abstract class
- Interface
Discountable
- Applies the discount feature for special menu items.
- Input Validation
- Ensures entered data (menu code, name, price, discount) adheres to defined rules.
- Dynamic Data Structure
- Uses
ArrayList
to store menu data, allowing flexible additions and deletions.
- Uses
- Text-Based Interaction
- Uses Scanner to process user input for CRUD operations (Create, Read, Update, Delete).
- Programming Language: Java
- Programming Paradigm: OOP (Object-Oriented Programming)
- Clone the Repository
git clone https://github.com/username/repository-name.git cd repository-name
- Compile the Program
Ensure you have the latest JDK installed.javac Main.java
- Run the Program
java Main
Here’s an example of what the application looks like when running:
===== Restaurant Menu Management =====
1. Add Menu
2. View All Menus
3. Delete Menu
4. Exit
Choose an option:
.
├── src/
│ ├── Main.java
│ ├── MenuItem.java
│ ├── RegularMenu.java
│ ├── SpecialMenu.java
│ └── Discountable.java
├── README.md
- Database Integration
- Store data permanently in databases like MySQL or PostgreSQL.
- Graphical User Interface (GUI)
- Improve user experience using JavaFX or Swing.
- Reporting Features
- Generate reports such as total revenue and the number of sold menu items.