forked from AY2324S2-CS2113-T12-4/tp
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/master'
- Loading branch information
Showing
3 changed files
with
33 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
@startuml | ||
'https://plantuml.com/sequence-diagram | ||
|
||
actor User | ||
|
||
participant "tagCommand(line: String, list: TravelActivityList)" as tagCommandMethod | ||
participant "list: TravelActivityList" as TravelActivityListInstance | ||
participant "OmniExceptionInstance: OmniException" as OmniExceptionInstance | ||
|
||
User -> tagCommandMethod: tagCommand(line, list) | ||
activate tagCommandMethod | ||
|
||
tagCommandMethod -> tagCommandMethod: line.split(" ") | ||
alt command.length == 3 && isNumeric(command[1]) | ||
tagCommandMethod -> tagCommandMethod: int listNumber = Integer.parseInt(command[1]) | ||
tagCommandMethod -> tagCommandMethod: String tag = command[2] | ||
tagCommandMethod -> TravelActivityListInstance: tagActivity(listNumber, tag) | ||
else command.length == 2 | ||
tagCommandMethod -> OmniExceptionInstance: OmniException("Please specify a tag name") | ||
else | ||
tagCommandMethod -> OmniExceptionInstance: OmniException("Please specify which task to tag") | ||
end | ||
|
||
deactivate tagCommandMethod | ||
@enduml |