forked from nus-cs2103-AY2223S1/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 branch 'master' into ug-delete-command
# Conflicts: # docs/DeveloperGuide.md
- Loading branch information
Showing
13 changed files
with
297 additions
and
4 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
@startuml | ||
start | ||
:User inputs buy command; | ||
|
||
'Since the beta syntax does not support placing the condition outside the | ||
'diamond we place it as the true branch instead. | ||
|
||
if () then ([command is valid argument]) | ||
:Executes buy command; | ||
|
||
else ([else]) | ||
endif | ||
stop | ||
@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,78 @@ | ||
@startuml | ||
!include style.puml | ||
|
||
box Logic LOGIC_COLOR_T1 | ||
participant ":LogicManager" as LogicManager LOGIC_COLOR | ||
participant ":JeeqTrackerParser" as JeeqTrackerParser LOGIC_COLOR | ||
participant ":BuyCommandParser" as BuyCommandParser LOGIC_COLOR | ||
participant "d:BuyCommand" as BuyCommand LOGIC_COLOR | ||
participant ":CommandResult" as CommandResult LOGIC_COLOR | ||
end box | ||
|
||
[-> LogicManager : execute("buy 1 q/10 g/Apple p/0.5 d/17/05/2000") | ||
activate LogicManager | ||
|
||
LogicManager -> JeeqTrackerParser : parseCommand("buy 1 q/10 g/Apple p/0.5 d/17/05/2000") | ||
activate JeeqTrackerParser | ||
|
||
create BuyCommandParser | ||
JeeqTrackerParser -> BuyCommandParser | ||
activate BuyCommandParser | ||
|
||
BuyCommandParser --> JeeqTrackerParser | ||
deactivate BuyCommandParser | ||
|
||
JeeqTrackerParser -> BuyCommandParser : parse("buy 1 q/10 g/Apple p/0.5 d/17/05/2000") | ||
activate BuyCommandParser | ||
|
||
create BuyCommand | ||
BuyCommandParser -> BuyCommand | ||
activate BuyCommand | ||
|
||
BuyCommand -> Model :getFilteredClientList() | ||
activate Model | ||
|
||
Model --> BuyCommand | ||
deactivate Model | ||
|
||
BuyCommand -> Client :addTransaction() | ||
activate Client | ||
|
||
Client --> BuyCommand | ||
deactivate Client | ||
|
||
BuyCommand -> Model :setClient() | ||
activate Model | ||
|
||
Model --> BuyCommand | ||
deactivate Model | ||
|
||
BuyCommand --> BuyCommandParser : d | ||
deactivate BuyCommand | ||
|
||
BuyCommandParser --> JeeqTrackerParser : d | ||
deactivate BuyCommandParser | ||
'Hidden arrow to position the destroy marker below the end of the activation bar. | ||
BuyCommandParser -[hidden]-> JeeqTrackerParser | ||
destroy BuyCommandParser | ||
|
||
|
||
JeeqTrackerParser --> LogicManager : d | ||
deactivate JeeqTrackerParser | ||
|
||
LogicManager -> BuyCommand : execute() | ||
activate BuyCommand | ||
|
||
create CommandResult | ||
BuyCommand -> CommandResult | ||
activate CommandResult | ||
|
||
CommandResult --> BuyCommand | ||
deactivate CommandResult | ||
|
||
BuyCommand --> LogicManager : result | ||
deactivate BuyCommand | ||
|
||
[<--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,38 @@ | ||
@startuml | ||
!include style.puml | ||
skinparam arrowThickness 1.1 | ||
skinparam arrowColor LOGIC_COLOR_T4 | ||
skinparam classBackgroundColor LOGIC_COLOR | ||
|
||
Class "{abstract}\nCommand" as Command | ||
Class BuyCommand | ||
|
||
package "Parser classes"{ | ||
Class "<<interface>>\nParser" as Parser | ||
Class JeeqTrackerParser | ||
Class BuyCommandParser | ||
Class CliSyntax | ||
Class ParserUtil | ||
Class ArgumentMultimap | ||
Class ArgumentTokenizer | ||
Class Prefix | ||
} | ||
|
||
Class HiddenOutside #FFFFFF | ||
HiddenOutside ..> JeeqTrackerParser | ||
|
||
JeeqTrackerParser .down.> BuyCommandParser: creates > | ||
|
||
BuyCommandParser ..> BuyCommand : creates > | ||
JeeqTrackerParser ..> Command : returns > | ||
BuyCommandParser .up.|> Parser | ||
BuyCommandParser ..> ArgumentMultimap | ||
BuyCommandParser ..> ArgumentTokenizer | ||
ArgumentTokenizer .left.> ArgumentMultimap | ||
BuyCommandParser ..> CliSyntax | ||
CliSyntax ..> Prefix | ||
BuyCommandParser ..> ParserUtil | ||
ParserUtil .down.> Prefix | ||
ArgumentTokenizer .down.> Prefix | ||
BuyCommand -up-|> Command | ||
@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,16 @@ | ||
@startuml | ||
!include style.puml | ||
skinparam ClassFontColor #000000 | ||
skinparam ClassBorderColor #000000 | ||
|
||
title Initial state | ||
|
||
package MainWindow { | ||
class State1 as "clients:ClientListPanel" | ||
class State2 as "companies:CompanyListPanel" | ||
class State3 as "transactions:TransactionListPanel" | ||
} | ||
State1 -[hidden]right-> State2 | ||
State2 -[hidden]right-> State3 | ||
@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,16 @@ | ||
@startuml | ||
start | ||
:User inputs edit command; | ||
|
||
'Since the beta syntax does not support placing the condition outside the | ||
'diamond we place it as the true branch instead. | ||
|
||
if () then ([command is valid argument]) | ||
:Executes edit command; | ||
|
||
:Display edited transaction | ||
with updated details; | ||
else ([else]) | ||
endif | ||
stop | ||
@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,59 @@ | ||
@startuml | ||
!include ../style.puml | ||
|
||
box Logic LOGIC_COLOR_T1 | ||
participant ":LogicManager" as LogicManager LOGIC_COLOR | ||
participant ":JeeqTrackerParser" as JeeqTrackerParser LOGIC_COLOR | ||
participant ":EditCommandParser" as EditCommandParser LOGIC_COLOR | ||
participant "d:EditTransactionCommand" as EditTransactionCommand LOGIC_COLOR | ||
participant ":CommandResult" as CommandResult LOGIC_COLOR | ||
end box | ||
|
||
[-> LogicManager : execute("edit") | ||
activate LogicManager | ||
|
||
LogicManager -> JeeqTrackerParser : parseCommand("edit") | ||
activate JeeqTrackerParser | ||
|
||
create EditCommandParser | ||
JeeqTrackerParser -> EditCommandParser | ||
activate EditCommandParser | ||
|
||
EditCommandParser --> JeeqTrackerParser | ||
deactivate EditCommandParser | ||
|
||
JeeqTrackerParser -> EditCommandParser : parse("edit") | ||
activate EditCommandParser | ||
|
||
create EditTransactionCommand | ||
EditCommandParser -> EditTransactionCommand | ||
activate EditTransactionCommand | ||
|
||
EditTransactionCommand --> EditCommandParser : d | ||
deactivate EditTransactionCommand | ||
|
||
EditCommandParser --> JeeqTrackerParser : d | ||
deactivate EditCommandParser | ||
'Hidden arrow to position the destroy marker below the end of the activation bar. | ||
EditCommandParser -[hidden]-> JeeqTrackerParser | ||
destroy EditCommandParser | ||
|
||
JeeqTrackerParser --> LogicManager : d | ||
deactivate JeeqTrackerParser | ||
|
||
LogicManager -> EditTransactionCommand : execute() | ||
activate EditTransactionCommand | ||
|
||
create CommandResult | ||
EditTransactionCommand -> CommandResult | ||
activate CommandResult | ||
|
||
CommandResult --> EditTransactionCommand | ||
deactivate CommandResult | ||
|
||
EditTransactionCommand --> LogicManager : result | ||
deactivate EditTransactionCommand | ||
|
||
[<--LogicManager | ||
deactivate LogicManager | ||
@enduml |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.