STUDENT NAME = "Johannes Aamot-Skeidsvoll"
STUDENT ID = "137410"
This project is a text-based user interface (TUI) application for managing groceries and recipes, focusing on reducing food waste by providing tools to track ingredients and suggest recipes based on available groceries. Users can add, remove, and list groceries, as well as manage recipes in a cookbook. The program is designed to be modular and easily extensible for future enhancements, such as future database integration and graphical user interfaces.
The program comes with a set of predefined groceries and recipes to demonstrate the functionality.
-
src/main/java/edu/ntnu/idi/idatt: Contains all the source code for the application.model: Data classes representing core entities likeGrocery,Recipe, andStorage.repository: In-memory storage classes for groceries and recipes, implementing repository interfaces.controller: Controllers to manage interactions between the data models and user interface.service: Business logic like ingredient validation and recipe suggestions.view: Display classes responsible for formatting outputs in the text-based interface.ui: Main user interface classes, includingTextMenuInterfacefor the TUI implementation.util: Utility classes for input validation and data population.
-
src/test/java/edu/ntnu/idi/idatt: Contains JUnit test classes for all critical components.- Tests are organized by package and validate functionality for models, controllers, repositories, and services.
GitHub Repository for IDATT1003 Portfolio Project
- Clone the repository to your local machine.
- Ensure that your Java environment is set up.
- Run the
Main.javafile located in thesrc/main/java/edu/ntnu/idi/idattpackage where the main method is located.
java src/main/java/edu/ntnu/idi/idatt/Main.javaRunning the main class will start the text-based user interface (TUI) for the application. Follow the on-screen instructions to interact with the program.
To run the tests, run
mvn test