Skip to content

Commit

Permalink
Finalise UG and DG
Browse files Browse the repository at this point in the history
  • Loading branch information
EugeneChanJiajun committed Apr 14, 2024
1 parent fe4b21c commit 6c80ab5
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 19 deletions.
21 changes: 14 additions & 7 deletions docs/DeveloperGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
* [Appendix: Requirements](#appendix-requirements)
* [Product scope](#product-scope)
* [User stories](#user-stories)
* [Use cases]
* [Non-functional requirements](#non-functional-requirements)
* [Glossary](#glossary)
* [Appendix: Instructions for manual testing](#appendix-instructions-for-manual-testing)
Expand Down Expand Up @@ -84,6 +83,7 @@ The parser component,
### TravelActivityTypes component

![TravelActivityTypeClassDiagram.png](TravelActivityTypeClassDiagram.png)

The TravelActivityTypes component consists of a few different classes:
* `Accommodation`: A subclass of travel activity related to accommodation
* `Food`: A subclass of travel activity related to food
Expand All @@ -106,6 +106,7 @@ the responses to the user.

### Errorhandlers component
![Errorhandlers.png](Errorhandler.png)

The Errorhandler component consists of two classes `CheckParameters` and `OmniException`.
`OmniException` is a subclass of the parent class `Exception`.

Expand Down Expand Up @@ -139,7 +140,7 @@ after using the bye command.
The above sequence diagram shows how existing save text files will be reloaded back into Omnibots array list to act as
a form of save feature when the user exits the bot.

![img_2.png](img_2.png)
![img_3.png](img_3.png)

The above class diagram shows the methods and the respective input and return types that the FileSave class contains. It
also shows the classes called during the file load sequence.
Expand All @@ -151,7 +152,7 @@ and each `TravelActivity` class object contains a date and duration. The `Travel
* `TravelActivityList#updateTravelActivity(travelActivityNumber, date, duration)`-- Updates the date and duration of the specified object of `TravelActivity` class type.

Step 1. When the user launches the app for the first time, there will be no objects of type `TravelActivity` in `travelActivities`.
Thus any attempts to call the command `update INDEX`
Thus, any attempts to call the command `update INDEX`
will result in an output telling the user that no travel activity can be found.

Step 2. After the user has added new travel activities into the `travelActivityList`, the user can execute
Expand Down Expand Up @@ -223,20 +224,24 @@ functions.
| v2.0 | user | have some form of QOL considerations like warning messages | know what are the errors that I have made in the inputs |
| v2.1 | user | be able to convert from one currency to another | know how much of a currency I need to convert for usage |
| v2.1 | user | be able to list all the tags I have given to the activities | easily see what are the tags I currently have in the list |
| v2.1 | user | be able to sort out the list of activities based on dates | easily view the entire flow of my travel plan |
| v2.1 | user | be able to group and delete similar activities | easily manage and delete similar plans in one go |


## Non-Functional Requirements

1. The program should be able to run on any mainstream OS with java 11 installed
2. Users should be able to
2. Users should be able to hold all travel plans in a typical travel period.
3. A user with above average typing speed for regular English text should be able to accomplish most of the tasks faster
using commands than using the mouse.

## Glossary

* Mainstream OS: Windows, Linux, MacOS

## Appendix: Instructions for manual testing
The instructions given below are used for testing the app manually.

The instructions given below are used for testing the app manually.

### Launch and shutdown
1. Initial launch
Expand All @@ -245,6 +250,8 @@ The instructions given below are used for testing the app manually.
2. Shutdown
1. When the app is running, type `bye` into the terminal to close the app.

More info can be found in the user guide [here](https://ay2324s2-cs2113-t12-4.github.io/tp/UserGuide.html).

### Adding a travel activity
1. Adding a general travel activity
1. Test case: `add visit Paris /date 2024-12-12 /duration 2 weeks`
Expand All @@ -255,7 +262,7 @@ The instructions given below are used for testing the app manually.

Expected: A new general activity is added with a tag and the details of the activity is shown

2. Adding a accommodation activity into the list
2. Adding an accommodation activity into the list
1. Test case: `accommodation hotel /date 2024-12-12 /duration one month`

Expected: A new accommodation activity type is added and the details of the activity is shown
Expand Down Expand Up @@ -477,4 +484,4 @@ The instructions given below are used for testing the app manually.
1. Shows all the commands the user can input
1. Test case: `help`

Expected: All the commands and their format will be shown
Expected: All the commands and their format will be shown
28 changes: 17 additions & 11 deletions docs/UserGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@ list via a Command Line Interface**.

## Quick Start

1. Ensure you have Java 11 or above installed in your Computer.
1. Ensure you have Java 11 installed in your Computer.

2. Download the latest omni.jar from here.
2. Download the latest omni.jar from [here]().

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

Expand Down Expand Up @@ -62,11 +62,11 @@ ____________________________________________________________
> e.g. `help 123` will just be intepreted as `help`.
> * Words that are in square brackets such as `[/tag TAG]` indicates that it is
> optional to include in the command.
> * Users should not use any `/` into their input descriptions unless using for input command format
> * Users should not use any `/` into their input descriptions unless using for input command format.

### Adding a general travel activity : `add`
Adds a general travel activity into the travel activity list
Adds a general travel activity into the travel activity list.
* This is for activities that do not fall under the other activity types. EG. visiting a country.

Format: `add DESCRIPTION /date YYYY-MM-DD /duration DURATION [/tag TAG]`
Expand All @@ -92,7 +92,7 @@ ____________________________________________________________
```

### Add an accommodation activity type into the list : `accommodation`
Adds an accommodation type travel activity into the travel activity list
Adds an accommodation type travel activity into the travel activity list.

Format: `accommodation DESCRIPTION /date YYYY-MM-DD /duration DURATION [/tag TAG]`

Expand Down Expand Up @@ -173,6 +173,7 @@ Find an activity based on their description. All activities with the given descr
Format: `find DESCRIPTION [/exclude KEYWORD]`
* `DESCRIPTION` has to match the activity description exactly to find the activity
* `DESCRIPTION` can also be a keyword that is included in the description.
* `/exclude KEYWORD` will exclude any keywords that appear in the resulting list based on what your description is.

Examples of usage (assuming saizeriya is in list):
* `find saizeriya`
Expand Down Expand Up @@ -229,6 +230,8 @@ Shows all activities for given date if date is provided.
Sorts by date if sort is enabled.

Format: `list [/date DATE /sort]`
* Using `list` with `/date DATE` will show all the activities with date `DATE`.
* Using `list` with `/sort` will show the list sorted by date.

Examples of usage:
* `list`
Expand Down Expand Up @@ -374,6 +377,7 @@ Find an activity based on their tag. All activities with the given tag will be l

Format: `findtag TAG [/exclude KEYWORD]`
* `TAG` has to match the activity tag exactly to find the activity
* `/exclude KEYWORD` will exclude any keywords found in the **description** of the activity

Examples of usage:
* `findtag spicy`
Expand Down Expand Up @@ -415,6 +419,7 @@ Find an activity based on their type. All activities with the given type will be
Format: `findtype TYPE [/exclude KEYWORD]`
* `TYPE` has to match the activity type exactly to find the activity
* The different types are `general`, `accommodation`, `food`, `landmark`
* `/exclude KEYWORD` will exclude any keywords found in the **description** of the activity

Examples of usage:
* `findtype general`
Expand All @@ -430,6 +435,7 @@ ____________________________________________________________
```

### Adding an expense amount: `expense`

Adds an expense amount to an existing travel activity.

Format: `expense INDEX EXPENSE`
Expand Down Expand Up @@ -486,7 +492,7 @@ ____________________________________________________________

### Converting a currency : `change`

Converts the currency from one currency to another
Converts the currency from one currency to another. (currency rates are adjusted in real time)

Format: `change AMOUNT /from CURRENCY1 /to CURRENCY2`
* `CURRENCY1` and `CURRENCY2` cannot be the same currency
Expand Down Expand Up @@ -526,22 +532,22 @@ same location of your other computer to transfer all the activities.

## Command Summary

* Get activity list `list`
* Get activity list `list [/date DATE /sort]`
* Get commands `help`
* Exit chatbot `bye`
* Add general travel activity `add DESCRIPTION /date YYYY-MM-DD /duration DURATION [/tag TAG]`
* Add accommodation type `accommodation DESCRIPTION /date YYYY-MM-DD /duration DURATION [/tag TAG]`
* Add Food type `food DESCRIPTION /date YYYY-MM-DD /duration DURATION [/tag TAG]`
* Add Landmark type `landmark DESCRIPTION /date YYYY-MM-DD /duration DURATION [/tag TAG]`
* Find activity using activity description `find DESCRIPTION`
* Delete travel activity `delete INDEX`
* Find activity using activity description `find DESCRIPTION [/exclude KEYWORD]`
* Delete travel activity `delete INDEX/ACTIVITY`
* Check activity as done `check INDEX`
* Uncheck activity as not done `uncheck INDEX`
* Update travel activity `update INDEX /date YYYY-MM-DD /duration DURATION [/tag TAG]`
* Add tag `tag INDEX TAGNAME`
* Remove tag `untag INDEX`
* Find activity using activity tag `findtag TAG`
* Find activity using activity type `findtype TYPE`
* Find activity using activity tag `findtag TAG [/exclude KEYWORD]`
* Find activity using activity type `findtype TYPE [/exclude KEYWORD]`
* Lists out all tags `listtags`
* Add expense `expense INDEX EXPENSE`
* Remove expense `removeexpense INDEX`
Expand Down
Binary file added docs/img_3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion docs/team/FileSaveUML.puml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@startuml

skinparam classAttributeIconSize 0
class User
class FileSave {
+ readFile(): void
Expand Down

0 comments on commit 6c80ab5

Please sign in to comment.