Skip to content

Latest commit

 

History

History
472 lines (328 loc) · 16.1 KB

UserGuide.adoc

File metadata and controls

472 lines (328 loc) · 16.1 KB

The Food Diary - User Guide

1. Welcome to the Food Diary

If you would like to get use the Food Diary straightaway, jump to the Section 2, “Quick Start” to get started

What is the Food Diary?

The Food Diary (FD) is a desktop app for storing your personal food reviews and obtain food recommendations based on your past reviews.

Why use the Food Diary?

FD is optimized for those who prefer to work with a Command Line Interface (CLI) while still having the benefits of a Graphical User Interface (GUI). If you can type fast, FD can get your foodie tasks done faster than traditional GUI apps. Additionally, FD also stores your data locally, ensuring that your privacy is protected.

Some of the features that can look forward to:

  • Keeping track of restaurants you’ve visited.

  • Getting an aggregate rating over all your visits.

  • Finding out about new restaurants near you for your next gastronomical adventure!

Callout

Callouts are boxes with important information regarding the usage of the Food Diary. These 3 callouts are used throughout our User Guide.

ℹ️
This is a note. A warning indicates important additional information that should be read.
💡
This is a tip. A tip indicates good to know information that would improve your user experience
⚠️
This is a warning. A warning indicates critical information that would affect the functionality of this programme.

2. Quick Start

  1. Ensure you have Java version 9 or later installed in your Computer.

  2. Download the latest fooddiary.jar here.

  3. Copy the file to the folder you want to use as the home folder for your Food Diary.

  4. Double-click the file to start the app. The GUI should appear in a few seconds.

    UiUpdated
  5. Type the command in the command box and press Enter to execute it.
    e.g. typing help and pressing Enter will open the help window.

  6. Some example commands you can try:

    • listRestaurants : lists all restaurants

    • addReview n/MCDONALDS r/4 m/delicious : adds a review to MCDONALDS with rating 4 with the comment "delicious"

    • delete3 : deletes the 3rd restaurant shown in the index

    • exit : exits the app

  7. Refer to Section 3, “Features” for details of each command.

3. Features

Command Format

  • Words in UPPER_CASE are the parameters to be supplied by the user e.g. in add n/RESTAURANT_NAME, RESTAURANT_NAME is a parameter which can be used as add n/Burger King.

  • Items in square brackets are optional.

  • Items with ​ after them can be used multiple times including zero times e.g. [t/TAG]…​ can be used as   (i.e. 0 times), t/friend, t/friend t/family etc.

  • Parameters can be in any order e.g. if the command specifies n/RESTAURANT_NAME r/STAR_RATING, r/STAR_RATING n/RESTAURANT_NAME is also acceptable.

3.1. Restaurant Commands

3.1.1. Adding a restaurant: add

Add a restaurant that is not found in the current list of restaurants.
Format: add n/RESTAURANT_NAME a/ADDRESS c/CUISINE

3.1.2. Editing details of a restaurant : edit

Edit the details of a restaurant identified by the index number used in the listRestaurants.
Format: edit INDEX [n/RESTAURANT_NAME] [a/ADDRESS] [c/CUISINE]

  • The index refers to the index number shown in the displayed restaurants list.

  • The index must be a positive integer 1, 2, 3, …​

Examples:

  • listRestaurants
    `editRestaurant 2 n/MACS `
    Change the name of the second restaurant in the list to MACS.

3.1.3. Deleting a restaurant: delete

Delete a restaurant that is in the current list of restaurants.
Format: delete INDEX

  • Deletes the restaurant at the specified INDEX.

  • The index refers to the index number shown in the displayed restaurants list.

  • The index must be a positive integer 1, 2, 3, …​

Examples:

  • delete 1
    Deletes the 1st restaurant in the Food Diary.

3.1.4. Listing all restaurants : list

Shows a list of all restaurants in the Food Diary with an option to filter for certain property.
Format: list [n/RESTAURANT_NAME] [a/ADDRESS] [c/CUISINE]

Examples:

  • list
    Return all the restaurants

Examples:

  • list
    Return all the restaurants

3.1.5. Listing all restaurants that you haven’t visited : listUnvisited

Shows a list of all restaurants that hasn’t been reveiwed by you, ranked based on the proximity to a given postal code.
Format: listUnvisited po/POSTAL_CODE

ℹ️
Calculation of proximity is based on postal codes. If no postal code or an invalid postal code is provided for a restaurant, it will appear at the bottom of the list.

Examples:

  • listUnvisitedpo/267951
    Return all the restaurants that has no reviews ranked based on the proximity to a given postal code

💡
If you simply want to view unreviewed restaurants, enter listUnvisited po/000000

3.1.6. Searching Restaurants by name: find

Find restaurants with names containing any of the given keywords.
Format: find KEYWORD [MORE_KEYWORD]

ℹ️
Only full words will be matched e.g. Mac would not return MacDonald’s

Examples:

  • find KFC
    Returns any restaurant with name containing KFC

3.2. Select a restaurant : select

Select a restaurant based on its index on the list and display information about it.
Format: select INDEX

  • The index refers to the index number show in the displayed restaurants list.

  • The index must be a positive integer 1, 2, 3, …​

Examples:

  • select 3
    Selects the restaurant in the displayed restaurants list with index 3 and displays its summary, reviews and website.

selectbefore

Figure 1. Before selecting any restaurant

selectafter

Figure 2. After selecting restaurant with index 3, Chilis' summary, reviews and website are displayed in the second, third and fourth panels (from left to right) respectively.

Note:

  • Placeholder for Restaurant Summary panel after changes to the Food Diary has been made will be coming in v1.4

  • Details of the restaurant in the Restaurant Summary beyond a certain length will be cut off. This will be dealt with in v1.4.

3.2.1. Setting the categories of a restaurant : setCategories

Set the cuisine of a restaurant identified by the index number used in the listRestaurants.
Format: setCategories INDEX [c/CUISINE] [o/OCCASION] [p/PRICE_RANGE]

  • The index refers to the index number show in the displayed restaurants list.

  • You need to ensure that the index entered must be a positive integer 1, 2, 3, …​

  • You need to ensure that the Price Range entered must only consist of 1-5 $ characters. e.g. $, $$$, $$$$$ is okay but $$$$$$, cheap or $expensive will be rejected.

  • You need to ensure that Cuisine and Occasion must only contain alphanumeric characters and spaces.

  • You do not need to worry about capitalization. Cuisine and Occasion will be autocapitalized. e.g. fast food and premium casual will be capitalized to Fast Food and Premium Casual. fAST fOOD will be converted into Fast Food.

Examples:

  • listRestaurants
    setCategory 2 c/Fine Dining o/Wedding p/$$$$$
    Set the categories of the second restaurant in the list to Find Dining for cuisine, Wedding for occasion and $$$$$ for price range.

Note:

  • setCategory for Cuisine, Occasion and Price Range supported as of v1.3

  • Autocomplete feature planned for v1.4

3.2.2. Filter restaurants based on category : filter

Filters and lists the restaurants with categories matching the keywords entered.
Format: filter KEYWORD [MORE_KEYWORDS]

  • You do not need to worry about case. Filtering is case insensitive. e.g. fast food will match Fast Food

  • You do not need to be concerned about which categories you want to filter. Filtering works across categories. e.g. japanese will match all restaurants with Cuisine set as Japanese or Price Range set as $$$$. Note this also means that the more keywords you add, the more general the filter becomes.

  • You can enter keywords in any order. $ casual is the same as casual $. Both will match restaurants that has Price Range as $ or Occasion as Casual.

  • You can filter multiple categories of the same type. e.g. japanese western will match both Japanese and Western cuisine restaurants. All Japanese and Western restaurants will be displayed.

  • You must enter words in full. e.g. fas foo will not match fast food

  • Restaurants matching at least one keyword will be displayed. e.g. fast food will match hawker food

Examples:

  • filter fast food
    Returns restaurants with Cuisine or Occasion matching fast or food

  • filter fast food casual Returns restaurants with Cuisine or Occasion matching fast, food or casual

  • filter $ Returns restaurants with Price Range matching $

  • filter $ casual western Return restaurants with Cuisine, Occasion or Price Range matching $, casual or western

3.2.3. Display website of selected restaurant : visitWeb

Format: visitWeb INDEX

  • The index refers to the index number shown in the displayed restaurants list.

  • The index must be a positive integer 1, 2, 3, …​

3.2.5. Display the website of any restaurant by entering its url.

Format: visitWeb URL
This allows users to visit website of any restaurant before they are entered into the list of restaurants in the FoodDiary. The purpose of this feature is so that users can reference from restaurants website when adding details of the restaurant into FoodDiary

  • A URL is a valid link to a website. It should be in this format: local-part.domain and adhere to the following contraints:

    1. The local-part should only contain alphanumeric characters and these special characters, excluding the parentheses, (!#$%&'*+/=?`{|}~^.-)

    2. This is followed by a '.' and then a domain name. The domain name must:

      • be at least 2 characters long

      • start and end with alphanumeric characters

      • consist of alphanumeric characters, a period or a hyphen for the characters in between, if any.

Examples:

  • list
    visitWeb 1
    Displays webpage of Restaurant at index 1 of list.

  • visitWeb www.jollibee.com.ph Displays webpage of Jollibee

3.3. Review Features

3.3.1. Adding a review: addReview

Adds a review to the Food Diary
Format: addReview INDEX re/ENTRY rr/RATING

  • Adds the review to the restaurant specified by the INDEX. The index refers to the index number of the restaurant of the currently displayed list of restaurants.. The index must be a positive integer 1, 2, 3, …​

  • ENTRY is a text field that include both alphabets and numbers.

  • RATING is a number that has to be a value from 0-5 inclusive. It represents a score out of 5 that is assigned to the restaurant with the added review.

  • Both fields (ENTRY and RATING) are compulsory and must be provided. There are no default values that either will take should the field be unspecified.

Examples:

  • addReview 2 re/Peach Pie was amazing rr/4

3.3.2. Editing a specified review : editReview

Edit selected fields in a specified entry.
Format: editReview INDEX [re/ENTRY] [rr/RATING]

  • Edits the review at the specified INDEX. The index refers to the index number of the review of the selected Restaurant. The index must be a positive integer 1, 2, 3, …​

  • A restaurant must be selected with a mouse click on the desired restaurant card (see screenshots below for an illustration)

  • At least one of the optional fields (either ENTRY or RATING) must be provided.

  • Existing values will be updated to the input values.

Steps to execute editReview command:

  • From the main screen of the application, first select a restaurant by clicking on it with the mouse.

UG editReview start

The above screenshot shows the case when no restaurant is selected. Upon selecting a restaurant, the reviews of the restaurant will show on the review panel, and the rightmost browser panel will show the webpage of the restaurant (if available) :

UG editReview selected restaurant
  • Following the above, enter the command:

UG editReview selected restaurant entered command
  • Upon successful execution of the command:

UG editReview command executed

Examples:

  • edit 1 rr/3
    Edits the rating of the 1st review to be 3.

  • edit 2 re/Food isn’t the best
    Edits the comment of the second review to "Food isn’t the best"

  • edit 2 re/Food isn’t the best rr/4
    Edits the comment of the second review to "Food isn’t the best" and the rating to be 4.

3.3.3. Deleting a review : deleteReview

Deletes the review from the Food Diary.
Format: deleteReview INDEX

  • Deletes the review at the specified INDEX. The index refers to the index number of the review of the selected Restaurant. The index must be a positive integer 1, 2, 3, …​

  • The index refers to the index number shown in the displayed reviews list.

  • The index must be a positive integer 1, 2, 3, …​

Examples:

  • deleteReview 2
    Deletes the 2nd review of the selected Restaurant in the Food Diary.

3.4. General Features

3.4.1. Viewing help : help

Format: help ==== Personalising your food diary with your name: name

Personalise your foodDiary with your name
Format: name n/YourName

Examples:

  • name n/Jack The Sheep

3.4.2. View your profile and usage statistics : view

Set the cuisine of a restaurant identified by the index number used in the listRestaurants.
Format: view

Examples:

view
View personalised statistics for John Doe. You have a total of 7 reviews and a total of 11 restaurants.

  • Example of profile statistics is shown below:

viewCommand

3.4.3. Exiting the program : exit

Exits the program.
Format: exit

Saving the data

Food diary data are saved in the hard disk automatically after any command that changes the data.
There is no need to save manually.

4. FAQ

Q: How do I transfer my data to another Computer?
A: Install the app in the other computer and overwrite the empty data file it creates with the file that contains the data of your previous Food Diary folder.

Q: How do I return to default screen?
A: Enter the command list to show all the restaurants.

5. Command Summary

Restaurant Class

  • add : add n/RESTAURANT_NAME a/ADDRESS c/CUISINE
    e.g. add n/Nana Thai food a/561 Clementi Road c/Thai

  • edit : edit INDEX [n/RESTAURANT_NAME] [a/ADDRESS] [c/CUISINE]
    e.g. listRestaurants
    editRestaurant 2 n/MACS

  • delete : delete INDEX
    e.g. delete 1

  • list : list [n/RESTAURANT_NAME] [a/ADDRESS] [c/CUISINE]
    e.g. list n/MacDonalds

  • listUnvisited : listUnvisited
    e.g. listUnvisited

  • setCategory : setCategory INDEX [c/CUISINE] [o/OCCASION] [p/PRICE_RANGE]
    e.g. listRestaurants
    setCategory 2 c/Fine Dining o/Wedding p/expensive

  • filter : filter KEYWORD [MORE_KEYWORDS]
    e.g. filter fast food gathering

  • visitWeb : visitWeb INDEX
    e.g. list
    visitWeb 1

Review Class

  • addReview : addReview INDEX re/ENTRY rr/RATING
    e.g. addReview 2 re/Peach Pie was amazing rr/4

  • editReview : edit INDEX [r/STAR_RATING] [m/COMMENT]
    e.g. edit 2 rr/Food isn’t the best

  • deleteReview : deleteReview INDEX_RESTAURANT INDEX_REVIEW
    e.g. delete 3 1

FoodDiary Class

  • name : name n/YourName
    e.g. name n/JackTheSheep

  • view : view
    e.g. view

Miscellaneous

  • help : help

  • exit : exit