forked from nus-cs2103-AY2021S1/tp
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #117 from TianYong-Goh/branch-DG-UG
Update DG and UG
- Loading branch information
Showing
14 changed files
with
342 additions
and
18 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
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
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,92 @@ | ||
@startuml | ||
!include style.puml | ||
|
||
box Logic LOGIC_COLOR_T1 | ||
participant ":LogicManager" as LogicManager LOGIC_COLOR | ||
participant ":WishfulShrinkingParser" as WishfulShrinkingParser LOGIC_COLOR | ||
participant ":EatRecipeCommandParser" as EatRecipeCommandParser LOGIC_COLOR | ||
participant "command :EatRecipeCommand" as EatRecipeCommand LOGIC_COLOR | ||
participant ":CommandResult" as CommandResult LOGIC_COLOR | ||
end box | ||
|
||
box Model MODEL_COLOR_T1 | ||
participant ":Model" as Model MODEL_COLOR | ||
participant ":WishfulShrinking" as WishfulShrinking MODEL_COLOR | ||
participant ":ConsumptionList" as ConsumptionList MODEL_COLOR | ||
end box | ||
|
||
[-> LogicManager : execute("eatR 1") | ||
activate LogicManager | ||
|
||
LogicManager -> WishfulShrinkingParser : parseCommand("eatR 1") | ||
activate WishfulShrinkingParser | ||
|
||
create EatRecipeCommandParser | ||
WishfulShrinkingParser -> EatRecipeCommandParser | ||
activate EatRecipeCommandParser | ||
|
||
EatRecipeCommandParser --> WishfulShrinkingParser | ||
deactivate EatRecipeCommandParser | ||
|
||
WishfulShrinkingParser -> EatRecipeCommandParser : parse("1") | ||
activate EatRecipeCommandParser | ||
|
||
create EatRecipeCommand | ||
EatRecipeCommandParser -> EatRecipeCommand | ||
activate EatRecipeCommand | ||
|
||
EatRecipeCommand --> EatRecipeCommandParser | ||
deactivate EatRecipeCommand | ||
|
||
EatRecipeCommandParser --> WishfulShrinkingParser : command | ||
deactivate EatRecipeCommandParser | ||
'Hidden arrow to position the destroy marker below the end of the activation bar. | ||
EatRecipeCommandParser -[hidden]-> WishfulShrinkingParser | ||
destroy EatRecipeCommandParser | ||
|
||
WishfulShrinkingParser --> LogicManager : command | ||
deactivate WishfulShrinkingParser | ||
|
||
LogicManager -> EatRecipeCommand : execute() | ||
activate EatRecipeCommand | ||
|
||
EatRecipeCommand -> Model : getFilteredRecipeList() | ||
activate Model | ||
|
||
Model --> EatRecipeCommand : List<Recipe> | ||
deactivate Model | ||
|
||
Model --> EatRecipeCommand | ||
deactivate Model | ||
|
||
EatRecipeCommand -> Model : addConsumption(1) | ||
activate Model | ||
|
||
Model -> WishfulShrinking : addConsumption(1) | ||
activate WishfulShrinking | ||
|
||
WishfulShrinking --> ConsumptionList: eat(1) | ||
activate ConsumptionList | ||
|
||
ConsumptionList --> WishfulShrinking | ||
deactivate ConsumptionList | ||
|
||
WishfulShrinking --> Model | ||
deactivate WishfulShrinking | ||
|
||
Model --> EatRecipeCommand | ||
deactivate Model | ||
|
||
create CommandResult | ||
EatRecipeCommand -> CommandResult | ||
activate CommandResult | ||
|
||
CommandResult --> EatRecipeCommand | ||
deactivate CommandResult | ||
|
||
EatRecipeCommand --> LogicManager : result | ||
deactivate EatRecipeCommand | ||
|
||
[<--LogicManager | ||
deactivate LogicManager | ||
@enduml |
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,20 @@ | ||
@startuml | ||
!include style.puml | ||
skinparam ClassFontColor #000000 | ||
skinparam ClassBorderColor #000000 | ||
|
||
title Step 1 | ||
|
||
class userInput | ||
class command | ||
|
||
package CollectionList { | ||
class recipeList | ||
class consumptionList | ||
} | ||
|
||
recipeList -[hidden]right-> consumptionList | ||
userInput -[hidden]up- recipeList | ||
userInput -> command | ||
|
||
@end |
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,22 @@ | ||
@startuml | ||
!include style.puml | ||
skinparam ClassFontColor #000000 | ||
skinparam ClassBorderColor #000000 | ||
|
||
title Step 2 | ||
|
||
class userInput | ||
class command | ||
class recipe | ||
|
||
package CollectionList { | ||
class recipeList | ||
class consumptionList | ||
} | ||
|
||
recipeList -[hidden]right-> consumptionList | ||
userInput -> command | ||
command -[hidden]right> recipe | ||
recipeList -down-> recipe | ||
|
||
@end |
Oops, something went wrong.