Skip to content
This repository was archived by the owner on Feb 6, 2020. It is now read-only.

Latest commit

 

History

History
1032 lines (702 loc) · 37.2 KB

File metadata and controls

1032 lines (702 loc) · 37.2 KB

PowerLifting Competition Coordinator - Developer Guide

1. Introduction

1.1. What is Powerlifting Competition Coordinator?

Powerlifting Competition Coordinator is a free application for powerlifting competition event organizers that is simple, fast, and easy to use. It is targeted at organizers of small to medium sized powerlifting competitions who require a hassle-free way of managing and tracking the lifts of participants in and out of the powerlifting competitions. During competition mode, the system has real time maintenance of athlete rankings within their respective weight classes allowing the organizer track the participants' standings at all times throughout the duration of the competition.

1.2. Core team

Powerlifting Competition Coordinator was developed and is maintained by Team T11-3. Feel free to contact us for any enquries.

1.3. Contributing

Powerlifting Competition Coordinator is an open source project and we would love to involve any contributor who has a passion for powerlifting. To get involved, start by reading Section 2, “Setting up”.

2. Setting up

This section includes the instructions to set up your development environment.

2.1. Prerequisites

Prior to setting up the project proper, make sure you have the following.

  1. JDK 11 or above

  2. IntelliJ IDE

    ℹ️
    IntelliJ by default has Gradle and JavaFx plugins installed.
    Do not disable them. If you have disabled them, go to File > Settings > Plugins to re-enable them.

2.2. Setting up the project in your computer

To setup the project in IntelliJ, follow the steps below.

  1. Fork this repo, and clone the fork to your computer.

  2. Open IntelliJ (if you are not in the welcome screen, click File > Close Project to close the existing project dialog first).

  3. Set up the correct JDK version for Gradle.

    1. Click Configure > Project Defaults > Project Structure.

    2. Click New…​ and find the directory of the JDK.

  4. Click Import Project.

  5. Locate the build.gradle file and select it. Click OK.

  6. Click Open as Project.

  7. Click OK to accept the default settings.

  8. Open a console and run the command gradlew processResources (Mac/Linux: ./gradlew processResources). It should finish with the BUILD SUCCESSFUL message.
    This will generate all resources required by the application and tests.

2.3. Verifying the setup

To verify that the setup is completed successfully, you should:

  1. Run the seedu.address.MainApp and try a few commands.

  2. Run the tests to ensure they all pass.

2.4. Configurations to do before writing code

This subsection includes configurations that you may find necessary or useful as you work on this project. We recommend that you make these configuration changes and additions before you start writing code.

2.4.1. Configurations to do before writing code

This subsection includes configurations that you may find necessary or useful as you work on this project. We recommend that you make these configuration changes and additions before you start writing code.

2.4.2. Configuring the coding style

This project follows oss-generic coding standards. IntelliJ’s default style is mostly compliant with ours but it uses a different import order from ours. Follow the instructions below to rectify this.

  1. Go to File > Settings…​ (Windows/Linux), or IntelliJ IDEA > Preferences…​ (macOS).

  2. Select Editor > Code Style > Java.

  3. Click on the Imports tab to set the order.

    • For Class count to use import with '*' and Names count to use static import with '*': Set to 999 to prevent IntelliJ from contracting the import statements.

    • For Import Layout: The order is import static all other imports, import java.*, import javax.*, import org.*, import com.*, import all other imports. Add a <blank line> between each import.

Optionally, you can follow the UsingCheckstyle.adoc document to configure Intellij to check style-compliance as you write code.

2.4.3. Updating documentation to match your fork

After forking the repo, links in the documentation will still point to the se-edu/addressbook-level3 repo. If you plan to develop this as a separate product (i.e. instead of contributing to the se-edu/addressbook-level3) , you should replace the URL in the variable repoURL in DeveloperGuide.adoc and UserGuide.adoc with the URL of your fork.

2.4.4. Setting up CI

Set up Travis to perform Continuous Integration (CI) for your fork. See UsingTravis.adoc to l earn how to set it up.

After setting up Travis, you can optionally set up coverage reporting for your team fork (see UsingCoveralls.adoc).

3. Design (Not finished)

This section documents the design and interaction of components in Powerlifting Competition Coordinator. Please take a moment to understand the different components before making any code changes.

3.1. Architecture

ArchitectureDiagram
Figure 1. Architecture Diagram

The Architecture Diagram given above explains the high-level design of the App. Given below is a quick overview of each component.

💡
The .puml files used to create diagrams in this document can be found in the diagrams folder. Refer to the Using PlantUML guide to learn how to create and edit diagrams.

Main has two classes called Main and MainApp. It is responsible for,

  • At app launch: Initializes the components in the correct sequence, and connects them up with each other.

  • At shut down: Shuts down the components and invokes cleanup method where necessary.

Commons represents a collection of classes used by multiple other components. The following class plays an important role at the architecture level:

  • LogsCenter : Used by many classes to write log messages to the App’s log file.

The rest of the App consists of four components.

  • UI: The UI of the App.

  • Logic: The command executor.

  • Model: Holds the data of the App in-memory.

  • Storage: Reads data from, and writes data to, the hard disk.

Each of the four components

  • Defines its API in an interface with the same name as the Component.

  • Exposes its functionality using a {Component Name}Manager class.

For example, the Logic component (see the class diagram given below) defines it’s API in the Logic.java interface and exposes its functionality using the LogicManager.java class.

LogicClassDiagram
Figure 2. Class Diagram of the Logic Component

How the architecture components interact with each other

The Sequence Diagram below shows how the components interact with each other for the scenario where the user issues the command delete 1.

ArchitectureSequenceDiagram
Figure 3. Component interactions for delete 1 command

The sections below give more details of each component.

3.2. UI component

UiClassDiagram
Figure 4. Structure of the UI Component

API : Ui.java

The UI consists of a MainWindow that is made up of parts e.g.CommandBox, ResultDisplay, PersonListPanel, StatusBarFooter etc. All these, including the MainWindow, inherit from the abstract UiPart class.

The UI component uses JavaFx UI framework. The layout of these UI parts are defined in matching .fxml files that are in the src/main/resources/view folder. For example, the layout of the MainWindow is specified in MainWindow.fxml

The UI component,

  • Executes user commands using the Logic component.

  • Listens for changes to Model data so that the UI can be updated with the modified data.

3.3. Logic component

LogicClassDiagram
Figure 5. Structure of the Logic Component

API : Logic.java

  1. Logic uses the AddressBookParser class to parse the user command.

  2. This results in a Command object which is executed by the LogicManager.

  3. The command execution can affect the Model (e.g. adding a person).

  4. The result of the command execution is encapsulated as a CommandResult object which is passed back to the Ui.

  5. In addition, the CommandResult object can also instruct the Ui to perform certain actions, such as displaying help to the user.

Given below is the Sequence Diagram for interactions within the Logic component for the execute("delete 1") API call.

DeleteSequenceDiagram
Figure 6. Interactions Inside the Logic Component for the delete 1 Command
ℹ️
The lifeline for DeleteCommandParser should end at the destroy marker (X) but due to a limitation of PlantUML, the lifeline reaches the end of diagram.

3.4. Model component

ModelClassDiagram
Figure 7. Structure of the Model Component

API : Model.java

The Model,

  • stores a UserPref object that represents the user’s preferences.

  • stores the Address Book data.

  • exposes an unmodifiable ObservableList<Person> that can be 'observed' e.g. the UI can be bound to this list so that the UI automatically updates when the data in the list change.

  • does not depend on any of the other three components.

ℹ️
As a more OOP model, we can store a Tag list in Address Book, which Person can reference. This would allow Address Book to only require one Tag object per unique Tag, instead of each Person needing their own Tag object. An example of how such a model may look like is given below.

BetterModelClassDiagram

3.5. Storage component

StorageClassDiagram
Figure 8. Structure of the Storage Component

API : Storage.java

The Storage component,

  • can save UserPref objects in json format and read it back.

  • can save the Address Book data in json format and read it back.

3.6. Common classes

Classes used by multiple components are in the seedu.addressbook.commons package.

4. Implementation

This section describes some noteworthy details on how certain features are implemented.

4.1. [Proposed] Undo/Redo feature

4.1.1. Proposed Implementation

The undo/redo mechanism is facilitated by VersionedAddressBook. It extends AddressBook with an undo/redo history, stored internally as an addressBookStateList and currentStatePointer. Additionally, it implements the following operations:

  • VersionedAddressBook#commit() — Saves the current address book state in its history.

  • VersionedAddressBook#undo() — Restores the previous address book state from its history.

  • VersionedAddressBook#redo() — Restores a previously undone address book state from its history.

These operations are exposed in the Model interface as Model#commitAddressBook(), Model#undoAddressBook() and Model#redoAddressBook() respectively.

Given below is an example usage scenario and how the undo/redo mechanism behaves at each step.

Step 1. The user launches the application for the first time. The VersionedAddressBook will be initialized with the initial address book state, and the currentStatePointer pointing to that single address book state.

UndoRedoState0

Step 2. The user executes delete 5 command to delete the 5th person in the address book. The delete command calls Model#commitAddressBook(), causing the modified state of the address book after the delete 5 command executes to be saved in the addressBookStateList, and the currentStatePointer is shifted to the newly inserted address book state.

UndoRedoState1

Step 3. The user executes add n/David …​ to add a new person. The add command also calls Model#commitAddressBook(), causing another modified address book state to be saved into the addressBookStateList.

UndoRedoState2
ℹ️
If a command fails its execution, it will not call Model#commitAddressBook(), so the address book state will not be saved into the addressBookStateList.

Step 4. The user now decides that adding the person was a mistake, and decides to undo that action by executing the undo command. The undo command will call Model#undoAddressBook(), which will shift the currentStatePointer once to the left, pointing it to the previous address book state, and restores the address book to that state.

UndoRedoState3
ℹ️
If the currentStatePointer is at index 0, pointing to the initial address book state, then there are no previous address book states to restore. The undo command uses Model#canUndoAddressBook() to check if this is the case. If so, it will return an error to the user rather than attempting to perform the undo.

The following sequence diagram shows how the undo operation works:

UndoSequenceDiagram
ℹ️
The lifeline for UndoCommand should end at the destroy marker (X) but due to a limitation of PlantUML, the lifeline reaches the end of diagram.

The redo command does the opposite — it calls Model#redoAddressBook(), which shifts the currentStatePointer once to the right, pointing to the previously undone state, and restores the address book to that state.

ℹ️
If the currentStatePointer is at index addressBookStateList.size() - 1, pointing to the latest address book state, then there are no undone address book states to restore. The redo command uses Model#canRedoAddressBook() to check if this is the case. If so, it will return an error to the user rather than attempting to perform the redo.

Step 5. The user then decides to execute the command list. Commands that do not modify the address book, such as list, will usually not call Model#commitAddressBook(), Model#undoAddressBook() or Model#redoAddressBook(). Thus, the addressBookStateList remains unchanged.

UndoRedoState4

Step 6. The user executes clear, which calls Model#commitAddressBook(). Since the currentStatePointer is not pointing at the end of the addressBookStateList, all address book states after the currentStatePointer will be purged. We designed it this way because it no longer makes sense to redo the add n/David …​ command. This is the behavior that most modern desktop applications follow.

UndoRedoState5

The following activity diagram summarizes what happens when a user executes a new command:

CommitActivityDiagram

4.1.2. Design Considerations

Aspect: How undo & redo executes
  • Alternative 1 (current choice): Saves the entire address book.

    • Pros: Easy to implement.

    • Cons: May have performance issues in terms of memory usage.

  • Alternative 2: Individual command knows how to undo/redo by itself.

    • Pros: Will use less memory (e.g. for delete, just save the person being deleted).

    • Cons: We must ensure that the implementation of each individual command are correct.

Aspect: Data structure to support the undo/redo commands
  • Alternative 1 (current choice): Use a list to store the history of address book states.

    • Pros: Easy for new Computer Science student undergraduates to understand, who are likely to be the new incoming developers of our project.

    • Cons: Logic is duplicated twice. For example, when a new command is executed, we must remember to update both HistoryManager and VersionedAddressBook.

  • Alternative 2: Use HistoryManager for undo/redo

    • Pros: We do not need to maintain a separate list, and just reuse what is already in the codebase.

    • Cons: Requires dealing with commands that have already been undone: We must remember to skip these commands. Violates Single Responsibility Principle and Separation of Concerns as HistoryManager now needs to do two different things.

4.2. [Proposed] Data Encryption

{Explain here how the data encryption feature will be implemented}

4.3. Logging

We are using java.util.logging package for logging. The LogsCenter class is used to manage the logging levels and logging destinations.

  • The logging level can be controlled using the logLevel setting in the configuration file (See Section 4.4, “Configuration”)

  • The Logger for a class can be obtained using LogsCenter.getLogger(Class) which will log messages according to the specified logging level

  • Currently log messages are output through: Console and to a .log file.

Logging Levels

  • SEVERE : Critical problem detected which may possibly cause the termination of the application

  • WARNING : Can continue, but with caution

  • INFO : Information showing the noteworthy actions by the App

  • FINE : Details that is not usually noteworthy but may be useful in debugging e.g. print the actual list instead of just its size

4.4. Configuration

Certain properties of the application can be controlled (e.g user prefs file location, logging level) through the configuration file (default: config.json).

5. Documentation

We use asciidoc for writing documentation.

ℹ️
We chose asciidoc over Markdown because asciidoc, although a bit more complex than Markdown, provides more flexibility in formatting.

5.1. Editing Documentation

See UsingGradle.adoc to learn how to render .adoc files locally to preview the end result of your edits. Alternatively, you can download the AsciiDoc plugin for IntelliJ, which allows you to preview the changes you have made to your .adoc files in real-time.

5.2. Publishing Documentation

See UsingTravis.adoc to learn how to deploy GitHub Pages using Travis.

5.3. Converting Documentation to PDF format

We use Google Chrome for converting documentation to PDF format, as Chrome’s PDF engine preserves hyperlinks used in webpages.

Here are the steps to convert the project documentation files to PDF format.

  1. Follow the instructions in UsingGradle.adoc to convert the AsciiDoc files in the docs/ directory to HTML format.

  2. Go to your generated HTML files in the build/docs folder, right click on them and select Open with → Google Chrome.

  3. Within Chrome, click on the Print option in Chrome’s menu. You should see a pop-up similar to Figure 12 below.

  4. Set the destination to Save as PDF, then click Save to save a copy of the file in PDF format. For best results, follow the settings as indicated in Figure 12.

chrome save as pdf
Figure 9. Saving documentation as PDF files in Chrome

6. Testing (Check this section at end of project!)

This section includes some information that may be useful for testing the project.

6.1. Running Tests

There are three ways to run tests.

💡
The most reliable way to run tests is the 3rd one. The first two methods might fail some GUI tests due to platform/resolution-specific idiosyncrasies.

Method 1: Using IntelliJ JUnit test runner

  • To run all tests, right-click on the src/test/java folder and choose Run 'All Tests'.

  • To run a subset of tests, you can right-click on a test package, test class, or a test and choose Run 'ABC'.

Method 2: Using Gradle

  • Open a console and run the command gradlew clean allTests (Mac/Linux: ./gradlew clean allTests).

ℹ️
See UsingGradle.adoc for more info on how to run tests using Gradle.

Method 3: Using Gradle (headless)

Thanks to the TestFX library we use, our GUI tests can be run in the headless mode. In the headless mode, GUI tests do not show up on the screen. That means the developer can do other things on the Computer while the tests are running.

To run tests in headless mode, open a console and run the command gradlew clean headless allTests (Mac/Linux: ./gradlew clean headless allTests).

6.2. Types of tests

We have two types of tests:

  1. GUI Tests - These are tests involving the GUI. They include:

    1. System Tests that test the entire App by simulating user actions on the GUI. These are in the systemtests package.

    2. Unit tests that test the individual components. These are in seedu.address.ui package.

  2. Non-GUI Tests - These are tests not involving the GUI. They include:

    1. Unit tests targeting the lowest level methods/classes.
      e.g. seedu.address.commons.StringUtilTest

    2. Integration tests that are checking the integration of multiple code units (those code units are assumed to be working).
      e.g. seedu.address.storage.StorageManagerTest

    3. Hybrids of unit and integration tests. These test are checking multiple code units as well as how the are connected together.
      e.g. seedu.address.logic.LogicManagerTest

6.3. Troubleshooting Testing

Problem: HelpWindowTest fails with a NullPointerException.

  • Reason: One of its dependencies, UserGuide.html in src/main/resources/docs is missing.

  • Solution: Execute Gradle task processResources.

Problem: AddCommandSystemTest or SearchCommandSystemTest fails with a GuiRobot$EventTimeoutException.

  • Reason: The required data could not be fetched from the online service within 10s. The service could be down at the moment.

  • Solution: Check that you are connected to the Internet, or if you are, try again later.

7. Dev Ops

This section contains some information or tools that may be useful for managing the project.

7.1. Build Automation

See UsingGradle.adoc to learn how to use Gradle for build automation.

7.2. Continuous Integration

We use CircleCI, Travis CI, and AppVeyor to perform Continuous Integration on our projects. See UsingCircleCI.adoc, UsingTravis.adoc, and UsingAppVeyor.adoc for more details.

7.3. Coverage Reporting

We use Coveralls to track the code coverage of our projects. See UsingCoveralls.adoc for more details.

7.4. Documentation Previews

When a pull request has changes to asciidoc files, you can use Netlify to see a preview of how the HTML version of those asciidoc files will look like when the pull request is merged. See UsingNetlify.adoc for more details.

7.5. Making a Release

Here are the steps to create a new release.

  1. Update the version number in MainApp.java.

  2. Generate a JAR file using Gradle.

  3. Tag the repo with the version number, e.g. v0.1.

  4. Create a new release using GitHub and upload the JAR file you created.

7.6. Managing Dependencies (Check this!!!)

A project often depends on third-party libraries. For example, PowerLifting Competition Coordinator depends on the Jackson library for XML parsing. We make use of Gradle to manage the project dependencies. Gradle can automate the downloading of these dependencies, saving us time and effort.

While strongly discouraged by us, you can nevertheless opt for one of the following alternatives.

  • Include those libraries in the repo (though this bloats the repo size).

  • Download those libraries manually (though this creates extra work for you).

Appendix A: Product Scope

Target user profile:

  • organizes small to medium sized powerlifting competitions

  • has a need to manage a significant number athletes during the competition

  • has a need to see the ranking of the participants of each competition

  • prefer desktop applicationss over other types

  • can type fast

  • prefers typing over mouse input

  • is reasonably comfortable using CLI apps

Value proposition: manage powerlifting competitions faster than a typical mouse/GUI driven app

Appendix B: User Stories

Priorities: High (must have) - * * *, Medium (nice to have) - * *, Low (unlikely to have) - *

Priority As a …​ I want to …​ So that I can…​

* * *

new user

see usage instructions

refer to instructions when I forget how to use the App

* * *

event organizer

create a new competition

start and organize a new competition

* * *

event organizer

find athletes according to their weight class

see which athletes are in the same competition

* * *

event organizer

sort athletes according to their attempted weights for different lifting events

adjust the weight on stage call for the next athlete to come and attempt their lift

* * *

event organizer

find which athletes are currently in the lead (individual lifts and aggregate score)

so that I can let the competitors know who is in the lead for their resepective weight classes and let them calculate what they need to do to win the competition

* * *

event organizer

the relative position of an athlete as compared to other athletes in their weight class

see which athletes are in the same competition

* * *

event organizer

edit the weight of a lifting attempt for an athlete

so that the lifting order of athletes can be updated

* * *

event organizer

update an athlete’s score after a successful lift

so that the ranking of the athletes can be updated

* * *

event organizer

edit an athlete’s name

update the athlete’s name in case the athletes have change their names or they were inputted incorrectly previously

* * *

event organizer

input/edit an athlete’s body weight

update the athlete’s weight so the athelete is taking part in the correct weight class

* * *

event organizer

record when a lifter fails/succeed in his/her lift

update the athlete’s score and ranking accordingly and to keep a record for how each athlete’s score was derived

* *

event organizer

input/edit an athlete’s country/club

which country/club the athlete is representing

* * *

event organizer

know the rack height for bench press/squat

the racks can be prepared before the athletes make their lifting attempt and save time

* *

user

hide private contact details by default

minimize chance of someone else seeing them by accident

*

event organizer

find which club/country an athlete is affiliated with

so that I know which countries/clubs can be ranked across the various weight classess

*

user with many persons in the address book

sort persons by name

locate a person easily

{More to be added}

Appendix C: Use Cases (To Do)

(For all use cases below, the System is the Powerlifting Competition Competitor and the Actor is the user, unless specified otherwise)

C.1. Out of competition mode

Use case: UC1 - View my competition list

MSS

  1. User requests to list all competitions in the system.

  2. System shows a list of competitions held based on the files in the folder.

    Use case ends.

Extensions

  • 2a. The list is empty.

    Use case ends.

Use case: UC2 - Add a new competition

MSS

  1. User requests for a new powerlifting competition to be started.

  2. User inputs the initial competition data (e.g. name, particpants) to be inputted.

  3. System adds the new competition to the user’s competition list.

  4. System shows a success message.

    Use case ends.

Extensions

  • 2a. Competition data is invalid.

    • 2a1. System shows an error message.

      Use case resume at step 2.

  • 2b. The competition name has already been used in user’s competition list.

    • 2b1. System tells user that the competition is already in his competition list.

      Use case ends.

Use case: UC3 - Delete a competition

MSS

  1. User obtains a list of competitions by listing (UC1)

  2. User requests for a new powerlifting competition to be deleted.

  3. System adds the new competition to the user’s competition list.

  4. System shows a success message.

    Use case ends.

Extensions

  • 2a. User gives an invalid index.

    • 2a1. System shows an error message.

      Use case resume at step 2.

Use case: UC4 - Enter competition mode for a particular competition

MSS

  1. User obtains a list of competitions by listing (UC1)

  2. User requests to enter competition mode for a particular competition.

  3. System enters competition mode for a particular competition.

    Use case ends.

Extensions

  • 2a. User gives an invalid index.

    • 2a1. System shows an error message.

      Use case resume at step 2.

Use case: UC5 - View my athlete list

MSS

  1. User requests to list all athletes in the system.

  2. Powerlifting Competition Coordinator shows a list of all athletes in the system.

    Use case ends.

Extensions

  • 2a. The list is empty.

    Use case ends.

Use case: UC6 - Search for athletes

MSS

  1. User performs a search with some constraints (e.g. id, country, age, etc.).

  2. System lists athletes satisfying all the constraints.

    Use case ends.

Extensions

  • 2a. System does not find any athletes satisfying all the constraints.

    • 2a1. System shows an empty list.

Use case: UC7 - View a specific athlete

MSS

  1. User obtains a list of athletes by listing (UC5). or searching (UC6).

  2. User requests to view more information on a specific athlete in the list.

  3. System shows detailed information of the book.

    Use case ends.

Extensions

  • 2a. System does not find the athlete in the list.

    Use case restarts from step 1.

  • 2b. User gives an invalid index.

    • 2b1. System shows an error message.

      Use case resumes at step 2.

Use case ends.

Use case: UC8 - Add an athlete

MSS

  1. User requests for an athlete to be added.

  2. User inputs athlete data.

  3. User confirms that the addition of the athlete cannot be reversed.

  4. System adds the new athlete to the user’s athlete list.

  5. System shows a success message.

    Use case ends.

Extensions

  • 2a. Athlete data is invalid.

    • 2a1. System shows an error message.

      Use case resume at step 2.

  • 2b. The athlete is already in user’s athlete list.

    • 2b1. System tells user that the athlete is already in his athlete list.

      Use case ends.

Use case: UC9 - Edit a specific athlete

MSS

  1. User views a specific athlete (UC7)

  2. User requests certain data about the athlete to be updated.

  3. System shows success message.

    Use case ends.

Extensions

  • 2a. User gives invalid data.

    • 2a1. System shows an error message.

      Use case resumes at step 2.

Use case: UC10 - Delete a specific athlete

MSS

  1. User views a specific athlete (UC7)

  2. User requests for an athlete to be deleted from the athlete list.

  3. System shows success message.

    Use case ends.

C.2. In competition mode

Use case: UC11 - View my participant list

MSS

  1. User requests to list all participants in the competition.

  2. System shows a list of all participants in the competition.

    Use case ends.

Extensions

  • 2a. The list is empty.

    Use case ends.

Use case: UC12 - Search/rank for participants

MSS 1. User performs a search with some constraints (e.g. id, country, age, ranking criteria etc.). 2. System lists participants satisfying all the constraints.

+ Use case ends.

Extensions

  • 2a. System does not find any athletes satisfying all the constraints.

    • 2a1. System shows an empty list.

Use case: UC13 - View a specific participant

MSS

  1. User obtains a list of athletes by listing (UC11). or searching (UC12).

  2. User requests to view more information on a specific athlete in the list.

  3. System shows detailed information of the book.

    Use case ends.

Extensions

  • 2a. System does not find the athlete in the list.

    Use case restarts from step 1.

  • 2b. User gives an invalid index.

    • 2b1. System shows an error message.

      Use case resumes at step 2.

Use case ends.

Use case: UC14 - Edit a specific participant

MSS

  1. User views a specific athlete (UC13)

  2. User requests certain data about the athlete to be updated.

  3. System shows success message.

    Use case ends.

Extensions

  • 2a. User gives invalid data.

    • 2a1. System shows an error message.

      Use case resumes at step 2.

Use case: UC15 - Disqualify a specific participant

MSS

  1. User views a specific participant (UC13)

  2. User requests for a particular athlete to be disqualified from the competition.

  3. System shows success message.

    Use case ends.

Use case: UC16 - Call for next participant in lifting order

MSS

  1. User requests for next athlete to attempt lift.

  2. System shows athlete that is lifting next.

  3. User updates system after athlete attempts lift.

  4. System shows success message.

    Use case ends.

Extensions

  • 2a. No more participants in lifting order.

    Use case ends.

Use case: UC16 - Exit competition

MSS

  1. User requests to exit competition mode.

  2. System exits competition mode.

    Use case ends.

C.2.1. Use case: UC16 - Finalize competition

MSS

  1. User requests to finalize competition data.

  2. System finalizes competition and prevents any further updating of the competition data.

    Use case ends.

Extensions

  • 2a. There are still participants that have not finished their lifts

    Use case ends.

{More to be added}

Appendix D: Non Functional Requirements

  1. Should work on any mainstream OS as long as it has Java 1.8.0_60 or higher installed.

  2. Should work on both 32-bit and 64-bit environments.

  3. Should come with automated unit tests and open source code.

  4. Should come with a user guide and a developer guide.

  5. Should favor DOS style commands over Unix-style commands.

  6. Should be intuitive such that a new user can learn to search and organize a powerlifting competition within 10 minutes.

  7. A user with above average typing speed for regular English text (i.e. not code, not system admin commands) should be able to accomplish most of the tasks faster using commands than using the mouse. {More to be added}

Appendix E: Glossary

Mainstream OS

Windows, Linux, Unix, OS-X

Private contact detail

A contact detail that is not meant to be shared with others

Appendix F: Product Survey

Product Name

Author: …​

Pros:

  • …​

  • …​

Cons:

  • …​

  • …​

Appendix G: Instructions for Manual Testing (To Do)

Given below are instructions to test the app manually.

ℹ️
These instructions only provide a starting point for testers to work on; testers are expected to do more exploratory testing.

G.1. Launch and Shutdown

  1. Initial launch

    1. Download the jar file and copy into an empty folder

    2. Double-click the jar file
      Expected: Shows the GUI with a set of sample contacts. The window size may not be optimum.

  2. Saving window preferences

    1. Resize the window to an optimum size. Move the window to a different location. Close the window.

    2. Re-launch the app by double-clicking the jar file.
      Expected: The most recent window size and location is retained.

{ more test cases …​ }

G.2. Deleting a person

  1. Deleting a person while all persons are listed

    1. Prerequisites: List all persons using the list command. Multiple persons in the list.

    2. Test case: delete 1
      Expected: First contact is deleted from the list. Details of the deleted contact shown in the status message. Timestamp in the status bar is updated.

    3. Test case: delete 0
      Expected: No person is deleted. Error details shown in the status message. Status bar remains the same.

    4. Other incorrect delete commands to try: delete, delete x (where x is larger than the list size) {give more}
      Expected: Similar to previous.

{ more test cases …​ }

G.3. Saving data

  1. Dealing with missing/corrupted data files

    1. {explain how to simulate a missing/corrupted file and the expected behavior}

{ more test cases …​ }