forked from AY2324S1-CS2103-W14-1/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.
- Loading branch information
1 parent
9bcaf22
commit 1e040d4
Showing
10 changed files
with
117 additions
and
57 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,19 @@ | ||
@startuml | ||
skin rose | ||
skinparam ActivityFontSize 15 | ||
skinparam ArrowFontSize 12 | ||
start | ||
:User executes ViewPolicyCommand; | ||
|
||
'Since the beta syntax does not support placing the condition outside the | ||
'diamond we place it as the true branch instead. | ||
|
||
if () then ([user keys in valid command format]) | ||
:Displays information about policy the user wants to view; | ||
else ([else]) | ||
:Display invalid command format error; | ||
stop | ||
endif | ||
:Display success message; | ||
stop | ||
@enduml |
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,77 @@ | ||
@startuml | ||
!include style.puml | ||
skinparam ArrowFontStyle plain | ||
|
||
box Logic LOGIC_COLOR_T1 | ||
participant ":LogicManager" as LogicManager LOGIC_COLOR | ||
participant ":AddressBookParser" as AddressBookParser LOGIC_COLOR | ||
participant ":ViewPolicyCommandParser" as ViewPolicyCommandParser LOGIC_COLOR | ||
participant "v:ViewPolicyCommand" as ViewPolicyCommand LOGIC_COLOR | ||
participant ":CommandResult" as CommandResult LOGIC_COLOR | ||
end box | ||
|
||
box Model MODEL_COLOR_T1 | ||
participant ":Model" as Model MODEL_COLOR | ||
end box | ||
|
||
[-> LogicManager : execute("viewPolicy 1 1") | ||
activate LogicManager | ||
|
||
LogicManager -> AddressBookParser : parseCommand("viewPolicy 1 1") | ||
activate AddressBookParser | ||
|
||
create ViewPolicyCommandParser | ||
AddressBookParser -> ViewPolicyCommandParser | ||
activate ViewPolicyCommandParser | ||
|
||
ViewPolicyCommandParser --> AddressBookParser | ||
deactivate ViewPolicyCommandParser | ||
|
||
AddressBookParser -> ViewPolicyCommandParser : parse("1 1") | ||
activate ViewPolicyCommandParser | ||
|
||
create ViewPolicyCommand | ||
ViewPolicyCommandParser -> ViewPolicyCommand | ||
activate ViewPolicyCommand | ||
|
||
ViewPolicyCommand --> ViewPolicyCommandParser : v | ||
deactivate ViewPolicyCommand | ||
|
||
ViewPolicyCommandParser --> AddressBookParser : v | ||
deactivate ViewPolicyCommandParser | ||
'Hidden arrow to position the destroy marker below the end of the activation bar. | ||
ViewPolicyCommandParser -[hidden]-> AddressBookParser | ||
destroy ViewPolicyCommandParser | ||
|
||
AddressBookParser --> LogicManager : v | ||
deactivate AddressBookParser | ||
|
||
LogicManager -> ViewPolicyCommand : execute(model) | ||
activate ViewPolicyCommand | ||
|
||
ViewPolicyCommand -> Model : get(1) | ||
activate Model | ||
|
||
Model --> ViewPolicyCommand | ||
deactivate Model | ||
|
||
ViewPolicyCommand -> Model : getPolicies() | ||
activate Model | ||
|
||
Model --> ViewPolicyCommand | ||
deactivate Model | ||
|
||
|
||
create CommandResult | ||
ViewPolicyCommand -> CommandResult | ||
activate CommandResult | ||
|
||
CommandResult --> ViewPolicyCommand | ||
deactivate CommandResult | ||
|
||
ViewPolicyCommand --> LogicManager : result | ||
deactivate ViewPolicyCommand | ||
|
||
[<--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
This file was deleted.
Oops, something went wrong.
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