Skip to content

Commit

Permalink
Merge pull request #103 from jianoway/edit-uml-diagram-jw
Browse files Browse the repository at this point in the history
Fix typos and diagrams in DG
  • Loading branch information
jianoway authored Oct 21, 2021
2 parents 49725c2 + 9809ea0 commit 5e1617b
Show file tree
Hide file tree
Showing 11 changed files with 6 additions and 51 deletions.
11 changes: 2 additions & 9 deletions docs/DeveloperGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -219,17 +219,10 @@ The following sequence diagram describes what happens when `AttendanceCommand` i

As seen from the diagram, the `AttendanceCommand` involves two for loops. In each of the loops there is a reference frame.

For `IndexWithinRange` and `UpdateModelAttendanceSequenceDiagram`, the sequential diagrams are as follows:private Model model = new ModelManager(getTypicalAcademyDirectory(), new UserPrefs());

![IndexWithinRangeSequenceDiagram](images/logic/commands/attendancecommand/IndexWithinRangeSequenceDiagram.png)

If the condition is met, a `CommandException` is thrown to let the user know that the `Index` input is invalid.
For `UpdateModelAttendanceSequenceDiagram`, the sequential diagrams can be found below:

![UpdateModelAttendanceSequenceDiagram](images/logic/commands/attendancecommand/UpdateModelAttendanceSequenceDiagram.png)

<div markdown="span" class="alert alert-info">:information_source: **Note:** There are 2 separate instances of `Student` as we are creating a new `Student` instance.

</div>

### ParticipationCommand

Expand All @@ -239,7 +232,7 @@ This command serves to update the `Participation` score of students. Following t

`ParticipationCommand` will extend the `Command` class and will consequently `@Override` the `Command#execute()` method to serve the aforementioned purpose.

The implementation is similar to `AttendanceCommand`, with the same sequence diagram being applicable for Participation given that the proper refactoring is done. `ParticipationCommand` has an additional section in the sequence diagram and it is located between the two loops in `AttendanceCommand`:
The implementation is similar to `AttendanceCommand`, with the same sequence diagram being applicable for Participation given that the proper refactoring is done. `ParticipationCommand` has an additional section in the sequence diagram located above the loop in `AttendanceCommand`.

![ParticipationCommandMarkAttendanceSequenceDiagram](images/logic/commands/participationcommand/ParticipationCommandMarkAttendanceSequenceDiagram.png)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,6 @@ activate ac
ac -> mm ++: getFilteredStudentList
mm --> ac --: lastShownList

loop for each Index in indexArrayList
ac -> i ++ : getZeroBased
i --> ac -- : zero based index
ac -> ol ++ : size
ol --> ac -- : size of lastShownList
ref over ac : IndexWithinRange
end loop

loop for each Index in indexArrayList
ac -> i ++ : getZeroBased
i --> ac -- : zero based index
Expand All @@ -33,8 +25,7 @@ loop for each Index in indexArrayList
st -> sr ++ : getAttendance
sr --> st --
st --> ac -- : attendanceToEdit
ac -> at ++ : update(studioSession, attendanceStatus)
deactivate at
ac -> at : update(studioSession, attendanceStatus)
ac -> st ++ : getParticipation
st -> sr ++ : getParticipation
sr --> st --
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

Participant ":AttendanceCommand" as ac LOGIC_COLOR
Participant ":StudioRecord" as sr LOGIC_COLOR
Participant ":Student" as st LOGIC_COLOR
Participant ":Student" as est LOGIC_COLOR
Participant ":ModelManager" as mm LOGIC_COLOR
Participant ":AcademyDirectory" as ad LOGIC_COLOR
Expand All @@ -13,18 +12,7 @@ activate ac
create sr
ac -> sr ++ : StudioRecord(attendanceToEdit, participation)
sr --> ac -- : newStudioRecord
ac -> st ++ : getName
st --> ac -- : name
ac -> st ++ : getPhone
st --> ac -- : phone
ac -> st ++ : getEmail
st --> ac -- : email
ac -> st ++ : getTelegram
st --> ac -- : telegram
ac -> st ++ : getAssessment
st --> ac -- : assessment
ac -> st ++ : getTags
st --> ac -- : tags


create est
ac -> est ++ : Student(name, phone, email, telegram, newStudioRecord, assessment, tags)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,13 @@
!include ../../../style.puml
Participant ":RetrieveCommand" as rc LOGIC_COLOR
Participant ":Model" as mm LOGIC_COLOR
Participant ":FilteredList" as fl LOGIC_COLOR
Participant ":CommandResult" as result LOGIC_COLOR

-> rc ++ :execute
loop for all InformationWantedFilter
rc -> rc ++ :executeFilter
rc -> mm ++ :getFilteredStudentListView(InformationWantedFilter)
return FilteredList
mm --> rc -- : FilteredList
deactivate
end
rc -> result ++ :CommandResult
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Participant ":UniqueStudentList" as usl LOGIC_COLOR
Participant ":AcademyDirectory" as mad LOGIC_COLOR
Participant ":UniqueStudentList" as musl LOGIC_COLOR
Participant ":CommandResult" as cr LOGIC_COLOR
Participant ":FilteredList" as fl LOGIC_COLOR


[-> sc : execute(model)
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
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.

0 comments on commit 5e1617b

Please sign in to comment.