- Main purpose: Create a Bread Recipe Manager to keep track of ingredients for intelligent ingredient shopping.
- Goals are:
- To practice input validation with try/catch blocks. Bad inputs are flagged in all steps of the application.
- Create nested menus
- Practice UI design in CLI
- Create structure for file reading (next version of the application)
OBS.: Some recipes were provided, with made up quantities for ingredients. For this version, it is not possible to add or remove any ingredient.
All the sections have input validation logic applied. Inputs are meant to be only integers, sometimes within a range. User is to be informed if a bad input is read and why it is not accepted.
- User can choose any of the options listed, each explained in following sections
- Application detects bad input (Strings, out-of-range ints, decimals...), prints a message error, and prevents the software to crash.
- Shows available recipes. This version only has 7.
- Inputing 0 takes user back to main menu.
- Inputing a recipe number will display info and instructions about the recipe (Example shows recipe number 5) :
- Let's user add a recipe to the shopping list and displays it.
- Keeps asking for recipe # until user hit 0, which will make the application go back to main menu
- If user inputs a negative number, will subtract from the list (Example below) :
- Based on the recipes chosen in option 2, application creates a shopping list, which adds all ingredients from all recipes into one table
- User can display the table in 2 measuring units, Metric and Imperial. This option can be changed in Main Menu
- User can change units of the application from metric to imperial and vice versa.
- Changes the units wherever there are ingredients being displayed.
- Displays the recipes the user added to the shopping list.
- Exits the application.
- Before exiting, the signture of the author is displayed
- Simply reprints the main menu endlessly.