Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CS2113-W13-2] FitTrack #22

Open
wants to merge 597 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 129 commits
Commits
Show all changes
597 commits
Select commit Hold shift + click to select a range
8f035e7
Merge branch 'master' of https://github.com/AY2425S1-CS2113-W13-2/tp …
Zackermax Nov 7, 2024
de93e86
Merge branch 'master' of https://github.com/Yvorm/tp
Yvorm Nov 7, 2024
b786d9a
Merge pull request #228 from Zackermax/205-docs-update-dg-for-v20
Zackermax Nov 7, 2024
c362a33
Merge branch 'master' of https://github.com/Yvorm/tp
Yvorm Nov 7, 2024
e1591c7
fix: correct return arrows in addTrainingSession puml diagram
CheeKiangg Nov 7, 2024
75d8979
feat: add GraphPerformanceTime class section in developer guide
CheeKiangg Nov 7, 2024
b028922
Docs: Update DG for V2.0
Zackermax Nov 7, 2024
a5c7bc6
Merge pull request #230 from CheeKiangg/Branch-UpdateDG
Zackermax Nov 7, 2024
93aeb62
Update DG for graph features.
TheDinos Nov 7, 2024
29ca26a
Merge branch 'master' into 205-docs-update-dg-for-high-level-function…
TheDinos Nov 7, 2024
b4d6db1
Merge pull request #231 from Zackermax/205-docs-update-dg-for-v20-2
CheeKiangg Nov 7, 2024
b746292
Merge branch 'master' of https://github.com/AY2425S1-CS2113-W13-2/tp …
TheDinos Nov 7, 2024
3f2cedc
Merge pull request #232 from TheDinos/205-docs-update-dg-for-high-lev…
CheeKiangg Nov 7, 2024
bb19f78
Update minor error in DG.
TheDinos Nov 7, 2024
e1f2ce6
Implement graphing functionality for user input.
TheDinos Nov 7, 2024
3baea89
Fix checkstyle.
TheDinos Nov 7, 2024
f6c3de1
Update checkstyle.
TheDinos Nov 7, 2024
11f8d5a
Merge pull request #234 from TheDinos/233-implement-user-input-for-gr…
TheDinos Nov 7, 2024
da7d9a1
Merge remote-tracking branch 'origin/update-UserGuide-V2' into dg-ug-…
Yvorm Nov 7, 2024
ea1cbfd
feat: update DG
CheeKiangg Nov 7, 2024
52ba4bd
feat: add PUML diagram for time based station graph
CheeKiangg Nov 7, 2024
0971c49
refactor: rename graphExerciseTime to generateMainGraphPerformance fo…
CheeKiangg Nov 7, 2024
da54dc1
fix: correct checkstyle.
CheeKiangg Nov 7, 2024
e745817
Merge pull request #235 from CheeKiangg/Branch-UpdateDGv2
TheDinos Nov 7, 2024
6f3bc32
Update point graphs functionality for UG.
TheDinos Nov 7, 2024
3d49df3
Fix minor ug mistakes.
TheDinos Nov 7, 2024
898ff87
Merge pull request #236 from TheDinos/207-update-ug-with-final-v20-fu…
CheeKiangg Nov 7, 2024
cd70cea
feat: add Display Performance Graph
CheeKiangg Nov 7, 2024
57707f2
refactor: ensure consistency in the itle of FitTrackCLI's Features
CheeKiangg Nov 7, 2024
2ca9916
Merge pull request #237 from CheeKiangg/Branch-UpdateUG
TheDinos Nov 7, 2024
e8c9b61
Update grade file to compile jar file.
TheDinos Nov 7, 2024
d65536a
Fix graph points parser bug.
TheDinos Nov 7, 2024
7d69e55
Removed Unneeded Classes
Yvorm Nov 7, 2024
d627d89
update individual contribution
CheeKiangg Nov 7, 2024
ede10cb
Docs: Update DG for V2.0
Zackermax Nov 7, 2024
27330af
Merge branch 'master' of https://github.com/AY2425S1-CS2113-W13-2/tp …
Zackermax Nov 7, 2024
e09602e
Merge pull request #241 from Zackermax/205-docs-update-dg-for-v20-3
CheeKiangg Nov 7, 2024
c3efc0e
Merge pull request #240 from CheeKiangg/Branch-IndividualContribution
Zackermax Nov 7, 2024
9684552
Feat: add comments for functions in GraphPerformance and GraphPerform…
CheeKiangg Nov 7, 2024
54638bf
Update build.gradle
TheDinos Nov 7, 2024
320e3d6
Merge pull request #239 from TheDinos/238-fix-bug-in-parser-for-graph…
Zackermax Nov 7, 2024
03e4bec
fix: correct checkstyle
CheeKiangg Nov 7, 2024
89fb56f
Merge pull request #243 from CheeKiangg/Branch-AddCommentsForGraphPer…
CheeKiangg Nov 7, 2024
e54fb77
Update UG and DG with link to NAPFA score table
CheeKiangg Nov 7, 2024
95bc537
Merge pull request #245 from CheeKiangg/Branch-InsertLinkToNAPFATable
CheeKiangg Nov 7, 2024
57c7fa9
Remove Unneeded Classes
Yvorm Nov 7, 2024
a538e8f
Add initial Save-File initialising & Parsing support
Yvorm Nov 7, 2024
9678a96
Update parsing logic
Yvorm Nov 7, 2024
aa10907
Remove unneeded methods
Yvorm Nov 7, 2024
cc74aa9
Rename misc commands
Yvorm Nov 7, 2024
4c9044f
Reimplement FoodEntry as Saveable subclass
Yvorm Nov 7, 2024
ae72e9f
Implement SaveFile Functionality for Food & Water Entries
Yvorm Nov 7, 2024
d82ad0d
Add Initial Changes to DG
Yvorm Nov 7, 2024
62b13a5
Merge branch 'master' of https://github.com/Yvorm/tp
Yvorm Nov 7, 2024
0946bed
Merge branch 'update-UserGuide-ReminderFunctionality' into food-water…
Yvorm Nov 7, 2024
16d5a06
UG Help Function Typo Fix
Zackermax Nov 7, 2024
6664921
Merge pull request #246 from AY2425S1-CS2113-W13-2/UG-Help-Function-T…
Zackermax Nov 7, 2024
babdbd6
Update DG and UG with Storage / Reminder / Water / Food function desc…
Yvorm Nov 7, 2024
aea96dd
Add missing classes
Yvorm Nov 7, 2024
4d59274
Fix CI failures
Yvorm Nov 7, 2024
5e75de1
Merge pull request #247 from Yvorm/food-water-storage-integration
Zackermax Nov 7, 2024
cb10c4f
Add DateTime parsing error messages
Yvorm Nov 10, 2024
ca690bb
Add JUnit testing for DateTimeParsing
Yvorm Nov 10, 2024
22ed9a7
Update DeleteReminder Index validation
Yvorm Nov 10, 2024
9d92422
Abstract Parser Helper Functions
Yvorm Nov 10, 2024
2aa142e
Parser now accepts lowercase exercise acronyms
Zackermax Nov 10, 2024
11ab74e
Merge pull request #309 from Zackermax/294-pe-dtester-d-error-message…
Zackermax Nov 10, 2024
67e9341
Explicitly list exercise acronyms in userguide and help function
Zackermax Nov 10, 2024
5c3457c
Updated sequence diagrams
Zackermax Nov 10, 2024
fa27c4c
Fix UserUpdate Logic
Yvorm Nov 10, 2024
ab7b3c4
Update Reminder-related functions + UG to use "//" as date/time marker
Yvorm Nov 10, 2024
b86ec29
Update missed UserUpdate function
Yvorm Nov 10, 2024
1599342
Add reminder class getter functions
Yvorm Nov 10, 2024
a9a67c1
Add JUnit tests for Reminder-Relation input parsing
Yvorm Nov 10, 2024
bb8c893
Add general JUnit test framework for Parsing testing
Yvorm Nov 10, 2024
cc38cf2
Correct reminder print function names
Yvorm Nov 10, 2024
6a57017
Update Parsing JUnit framework
Yvorm Nov 10, 2024
1aa47aa
Merge branch 'master' into fix-reminder-bugs
Yvorm Nov 10, 2024
c97f175
Merge pull request #310 from Zackermax/263-pe-dtester-c-exercise-acro…
Zackermax Nov 10, 2024
88b4894
Fix CI failures
Yvorm Nov 10, 2024
fba8cbf
Created modify DateTime command, functionality and documentation
Zackermax Nov 10, 2024
8b27dfc
Updated PPP
Zackermax Nov 10, 2024
4965b96
Updated User Stories
Zackermax Nov 10, 2024
0b87fd4
Update PPP name
Zackermax Nov 10, 2024
e484bf8
exception catching for date time format for reminders
ayushi0803 Nov 10, 2024
973345e
checkstyle
ayushi0803 Nov 10, 2024
ef800fe
documentation suggestions
ayushi0803 Nov 11, 2024
10f4d90
goal line separator added
ayushi0803 Nov 11, 2024
3b33856
Standardization of Visual Output Bordering for Error Input
ayushi0803 Nov 11, 2024
641591f
fitnes goal text - editing the goal to pass the test with deadline
ayushi0803 Nov 11, 2024
813d0f7
fixing the add-goal ex[pected outputs
ayushi0803 Nov 11, 2024
e4328f4
fitness goal test
ayushi0803 Nov 11, 2024
72cd6a8
fitness goal test
ayushi0803 Nov 11, 2024
31c8369
Merge branch 'goal-line-separator' of github.com:ayushi0803/tP into g…
ayushi0803 Nov 11, 2024
fb73bc8
checkstyle
ayushi0803 Nov 11, 2024
88c4713
Fix formatting in TrainingSession.
TheDinos Nov 11, 2024
dc00214
Update checking of valid inputs for shuttle run and walk and run.
TheDinos Nov 11, 2024
2e15f77
Add JUnit tests for valid user inputs of walk and run and shuttle run.
TheDinos Nov 11, 2024
db03ae8
Merge pull request #312 from Zackermax/307-pe-dtester-c-add-session-f…
TheDinos Nov 11, 2024
caa64a3
feat: Update FAQ in User Guide
CheeKiangg Nov 11, 2024
2f78230
Merge pull request #316 from TheDinos/253-pe-dtester-e-error-handling…
CheeKiangg Nov 11, 2024
fcd8367
Merge branch 'master' into Branch-UserGuideFAQ
CheeKiangg Nov 11, 2024
25ab1f5
Update UG with summarised table of formats for all exercises.
TheDinos Nov 11, 2024
8baf003
Merge pull request #317 from CheeKiangg/Branch-UserGuideFAQ
TheDinos Nov 11, 2024
a33037b
Merge pull request #318 from TheDinos/305-pe-dtester-c-edit-function-…
CheeKiangg Nov 11, 2024
749f9ca
Add missing commands gpoints and gperformance to help command in both…
TheDinos Nov 11, 2024
766fdb6
Merge pull request #319 from TheDinos/304-pe-dtester-d-help-command-d…
Zackermax Nov 11, 2024
f11edb5
Merge pull request #315 from ayushi0803/goal-line-separator
Zackermax Nov 11, 2024
c4c99fc
add Modify command in summary
CheeKiangg Nov 11, 2024
2429460
Update UG to reflect changes in modify command.
TheDinos Nov 11, 2024
3e31a69
user guide documentation update on goals (delete and list)
ayushi0803 Nov 11, 2024
c29b0d7
Merge pull request #322 from CheeKiangg/Branch-addmodifycommand
Zackermax Nov 11, 2024
88e798c
remove example from list-goal
ayushi0803 Nov 11, 2024
faa6d9c
goal commenting
ayushi0803 Nov 11, 2024
0407a5f
health profile comments
ayushi0803 Nov 11, 2024
2d15dc2
Implement reordering of trainingsession objects when datetime is chan…
TheDinos Nov 11, 2024
be8af2f
Implement JUnit tests to check for reordering of trainingsessions.
TheDinos Nov 11, 2024
caca0ab
Update JUnit function name for checkstyle.
TheDinos Nov 11, 2024
d674f47
parser comments
ayushi0803 Nov 11, 2024
41dcdbc
fit track and user comments
ayushi0803 Nov 11, 2024
307f08e
calculator comments
ayushi0803 Nov 11, 2024
ff07edc
pull up calc comments
ayushi0803 Nov 11, 2024
dddbd4d
calculator comments
ayushi0803 Nov 11, 2024
7404bf1
checkstyle errors
ayushi0803 Nov 11, 2024
0faf2c3
Merge pull request #325 from TheDinos/307-pe-dtester-c-add-session-fu…
Zackermax Nov 11, 2024
10f3da1
Merge pull request #326 from ayushi0803/comments-contributions-
Zackermax Nov 11, 2024
3520e35
Ayushi.md File updation
ayushi0803 Nov 11, 2024
759a24a
ayushi.md file contribution updation
ayushi0803 Nov 11, 2024
bda276f
rename file
ayushi0803 Nov 11, 2024
5bcdb1d
Merge branch 'master' into fix-reminder-bugs
Yvorm Nov 11, 2024
816a175
Fix JUnit test broken by merge
Yvorm Nov 11, 2024
4d2edef
Correct CI issues in JUnit Tests
Yvorm Nov 11, 2024
0af1b32
Correct CI issues in JUnit Tests
Yvorm Nov 11, 2024
226119e
Merge branch 'fix-reminder-bugs' of https://github.com/Yvorm/tp into …
Yvorm Nov 11, 2024
303f7e7
Final CI pass
Yvorm Nov 11, 2024
2624865
Merge pull request #327 from ayushi0803/Contributions-
Zackermax Nov 11, 2024
45f75ca
Merge pull request #311 from Yvorm/fix-reminder-bugs
Zackermax Nov 11, 2024
717ce23
Update contribution page and JUnit tests
Zackermax Nov 11, 2024
b6dec0d
Add rejection of vertical bar input and JUnit testing
Yvorm Nov 11, 2024
1cee12d
Add user initialisation from SaveFile
Yvorm Nov 11, 2024
d38f792
Add data_delimiter and data_delimiter_regex to standardise input parsing
Yvorm Nov 11, 2024
df27a80
Update UpdateSaveFile methods in program to match new params
Yvorm Nov 11, 2024
a4f5fa8
CI fix
Zackermax Nov 11, 2024
493e2de
Merge pull request #329 from Yvorm/fix-SaveFile-bugs
Zackermax Nov 11, 2024
d0fbbce
Merge branch 'master' of https://github.com/AY2425S1-CS2113-W13-2/tp …
Zackermax Nov 11, 2024
226c6bc
CI fix
Zackermax Nov 11, 2024
9e2218a
Merge pull request #328 from Zackermax/210-finish-contribution-page
Zackermax Nov 11, 2024
fb6dd26
Fixed user initialisation
Zackermax Nov 11, 2024
2687501
Merge pull request #330 from Zackermax/210-finish-contribution-page-1
TheDinos Nov 11, 2024
ce05b52
Parser accepts uppercase inputs
Zackermax Nov 11, 2024
deefed1
health profile tests
ayushi0803 Nov 11, 2024
04dfc5b
Merge pull request #332 from Zackermax/331-accept-uppercase-commands-…
TheDinos Nov 11, 2024
b771c61
food entry test
ayushi0803 Nov 11, 2024
5ffbdb9
removing unused imports
ayushi0803 Nov 11, 2024
617cc90
checkstyle
ayushi0803 Nov 11, 2024
98438eb
checkstyle fixes
ayushi0803 Nov 11, 2024
160eb23
contribution update
ayushi0803 Nov 11, 2024
c1a0082
Merge pull request #333 from ayushi0803/J-unit
Zackermax Nov 11, 2024
1f9058e
New JUnit Tests for Ui
Zackermax Nov 11, 2024
dee4581
CI fix
Zackermax Nov 11, 2024
b3631dd
Merge pull request #337 from Zackermax/335-junit-tests-80-line-coverage
Zackermax Nov 11, 2024
e8cf557
add fitness goal test and food intake test full coverages
ayushi0803 Nov 11, 2024
93dc60c
Add JavaDocs for TrainingSession.
TheDinos Nov 11, 2024
c5070b9
Add JUnit tests for TrainingSession class.
TheDinos Nov 11, 2024
d65e763
checkstyle
ayushi0803 Nov 11, 2024
aab3c9e
import removed
ayushi0803 Nov 11, 2024
66ae3a3
indentation
ayushi0803 Nov 11, 2024
1ce5be8
Fix checkstyle.
TheDinos Nov 11, 2024
ea3098a
Adhere to coding standard
CheeKiangg Nov 11, 2024
e766127
Merge pull request #342 from CheeKiangg/Branch-EnsureCodeQuality
TheDinos Nov 11, 2024
c4e3e28
Merge pull request #340 from TheDinos/339-update-javadoc-and-junit-te…
CheeKiangg Nov 11, 2024
7178a5f
Update UG with more information about set user usage.
TheDinos Nov 11, 2024
b28266f
Merge pull request #344 from TheDinos/343-update-ug
TheDinos Nov 11, 2024
0fd769c
Fix crashes related to input containing "|" character
Yvorm Nov 11, 2024
2bf10e8
Merge branch 'master' into update-JUnit-tests
Yvorm Nov 11, 2024
b781514
Add reminder class JUnit tests
Yvorm Nov 11, 2024
332830b
feat: add test class for GraphPerformanceTime
CheeKiangg Nov 11, 2024
3a46c44
Update DG.
TheDinos Nov 11, 2024
63078b5
fix ci
CheeKiangg Nov 11, 2024
6a95f27
Update DG.
TheDinos Nov 11, 2024
59459f2
Merge branch 'master' into 346-update-dg
TheDinos Nov 11, 2024
59d7e03
Merge pull request #345 from CheeKiangg/Branch-GraphPerformanceTimeTe…
TheDinos Nov 11, 2024
db6e070
Merge pull request #347 from TheDinos/346-update-dg
CheeKiangg Nov 11, 2024
41e9850
Feat: update PPP
CheeKiangg Nov 11, 2024
93d6150
Merge pull request #349 from CheeKiangg/PPP
CheeKiangg Nov 11, 2024
7e069a0
Update thedinos ppp.
TheDinos Nov 11, 2024
66f6115
Update minor errors in thedinos ppp.
TheDinos Nov 11, 2024
fc22211
Merge pull request #350 from TheDinos/348-update-contribution-page
CheeKiangg Nov 11, 2024
77398ca
display sequence diagram below workflow
CheeKiangg Nov 11, 2024
d64cd83
Merge pull request #352 from CheeKiangg/FormatDGv2.1
TheDinos Nov 11, 2024
b359180
Fix bug with ParserTest logic
Yvorm Nov 12, 2024
9f3a672
Add Storage JUnit Tests
Yvorm Nov 12, 2024
0075c64
Edit Reminder JUnit logic
Yvorm Nov 12, 2024
89dd172
Merge pull request #338 from ayushi0803/testing
Zackermax Nov 12, 2024
5001b50
Extend Storage JUnit Coverage
Yvorm Nov 12, 2024
ab0b8bf
Merge branch 'master' into update-JUnit-tests
Yvorm Nov 12, 2024
6573bf7
Updated PPP
Zackermax Nov 12, 2024
f0a4f8e
Merge pull request #353 from Yvorm/update-JUnit-tests
Zackermax Nov 12, 2024
dee71e9
Merge branch 'master' of https://github.com/AY2425S1-CS2113-W13-2/tp …
Zackermax Nov 12, 2024
94f900b
Merge pull request #354 from Zackermax/348-update-contribution-page
CheeKiangg Nov 12, 2024
85051d5
Initial Junit test files
TheDinos Nov 12, 2024
4291b4d
Merge branch 'master' into 335-junit-tests-graph
TheDinos Nov 12, 2024
c348ec9
General bugfixes
Zackermax Nov 12, 2024
e8a9471
Merge pull request #355 from Zackermax/335-junit-tests-80-line-covera…
CheeKiangg Nov 12, 2024
a71af52
Add Reminder-Related-Parser JUnit tests
Yvorm Nov 12, 2024
f41fff2
Fix logic error in TrainingSession toSaveString method
Yvorm Nov 12, 2024
ea64fc1
Add JUnit tests for GraphPoints.
TheDinos Nov 12, 2024
dac86de
Add JUnit tests for GraphPerformance.
TheDinos Nov 12, 2024
f6da4c4
Fix modifySession method savefile + printing functionality
Yvorm Nov 12, 2024
e6338f4
Merge branch 'master' into add-ReminderParser-JUnit-tests
Yvorm Nov 12, 2024
ab26ad6
Add Javadocs to Graph classes.
TheDinos Nov 12, 2024
340f387
update PPP
CheeKiangg Nov 12, 2024
85678fb
Fix checkstyle.
TheDinos Nov 12, 2024
5ef38a3
Merge pull request #359 from CheeKiangg/PPP-finalised
CheeKiangg Nov 12, 2024
8ecfa09
Fix checkstyle.
TheDinos Nov 12, 2024
d816cd6
Merge pull request #356 from Yvorm/add-ReminderParser-JUnit-tests
TheDinos Nov 12, 2024
f810785
Merge pull request #357 from TheDinos/335-junit-tests-graph
TheDinos Nov 12, 2024
8ff5da9
Fix formatting for table.
TheDinos Nov 12, 2024
c835d14
Update PPP.
TheDinos Nov 12, 2024
acd1175
remove duplicate
CheeKiangg Nov 12, 2024
07b9755
Merge pull request #360 from TheDinos/358-final-update-to-ppp
TheDinos Nov 12, 2024
c6b71c5
Updated PPP
Yvorm Nov 12, 2024
12aa540
Merge branch 'PPP-finalisedversion' into FinalPPP
CheeKiangg Nov 12, 2024
5b2f65a
remove duplicate
CheeKiangg Nov 12, 2024
97682a8
Update thedinos ppp.
TheDinos Nov 12, 2024
bcc6982
Merge pull request #362 from Yvorm/update-PPP-AvjayBhar
CheeKiangg Nov 12, 2024
5e2efc9
Merge pull request #361 from CheeKiangg/FinalPPP
CheeKiangg Nov 12, 2024
3679bc7
Merge pull request #363 from TheDinos/358-final-update-to-ppp2
TheDinos Nov 12, 2024
d5370c7
Merge branch 'master' into FinalPPPv2.1
TheDinos Nov 12, 2024
e9394fc
Merge pull request #364 from CheeKiangg/FinalPPPv2.1
CheeKiangg Nov 12, 2024
4717a5b
Update UG
Yvorm Nov 12, 2024
2769193
Merge branch 'master' into update-UG
Yvorm Nov 12, 2024
c3ee374
shorten description
CheeKiangg Nov 12, 2024
61d432e
Merge pull request #365 from CheeKiangg/PPP_v
CheeKiangg Nov 12, 2024
3b8d23b
Add PPP
TheDinos Nov 12, 2024
38e3631
Update README to reflect UG.
TheDinos Nov 12, 2024
24d05a7
Merge pull request #366 from TheDinos/358-final-update-to-readme
CheeKiangg Nov 12, 2024
43c9494
Add files via upload
CheeKiangg Nov 12, 2024
15c0e04
Add DG diagrams / UML
Yvorm Nov 12, 2024
7746629
Update Reminder-related DG entries
Yvorm Nov 12, 2024
77c7e1a
Update Storage Class diagram
Yvorm Nov 12, 2024
3b34ba1
Add misc Updates to DG
Yvorm Nov 12, 2024
639c903
Update Documentation
Yvorm Nov 12, 2024
bfe6bf4
Refactor PPP
Zackermax Nov 12, 2024
78479f9
Refactor PPP
Zackermax Nov 12, 2024
06fe873
Merge pull request #368 from Yvorm/update-UG-DG
Zackermax Nov 12, 2024
8da8723
Merge branch 'master' of https://github.com/AY2425S1-CS2113-W13-2/tp …
Zackermax Nov 12, 2024
e2aee92
Merge pull request #369 from Zackermax/367-refactor-ppp-name
CheeKiangg Nov 12, 2024
97cd54f
Refactor AboutUs
Zackermax Nov 12, 2024
5a63a3f
Merge pull request #371 from Zackermax/370-refactor-aboutus
Zackermax Nov 12, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions FitTrackLogger.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Oct 15, 2024 9:11:30 PM fittrack.logger.FitTrackLogger setupLogger
INFO: Logger successfully initialized
Oct 15, 2024 9:11:30 PM fittrack.storage.Storage initialiseSaveFile
INFO: Accessing existing save file...
Oct 15, 2024 9:11:30 PM fittrack.storage.Storage loadSaveFile
INFO: Save file successfully loaded.
Empty file added FitTrackLogger.log.lck
Empty file.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Duke project template
# fittrack

This is a project template for a greenfield Java project. It's named after the Java mascot _Duke_. Given below are instructions on how to use it.

Expand All @@ -8,7 +8,7 @@ Prerequisites: JDK 17 (use the exact version), update Intellij to the most recen

1. **Ensure Intellij JDK 17 is defined as an SDK**, as described [here](https://www.jetbrains.com/help/idea/sdk.html#set-up-jdk) -- this step is not needed if you have used JDK 17 in a previous Intellij project.
1. **Import the project _as a Gradle project_**, as described [here](https://se-education.org/guides/tutorials/intellijImportGradleProject.html).
1. **Verify the setup**: After the importing is complete, locate the `src/main/java/seedu/duke/Duke.java` file, right-click it, and choose `Run Duke.main()`. If the setup is correct, you should see something like the below:
1. **Verify the setup**: After the importing is complete, locate the `src/main/java/fittrack/duke/Duke.java` file, right-click it, and choose `Run Duke.main()`. If the setup is correct, you should see something like the below:
```
> Task :compileJava
> Task :processResources NO-SOURCE
Expand Down Expand Up @@ -39,7 +39,7 @@ Prerequisites: JDK 17 (use the exact version), update Intellij to the most recen

### JUnit tests

* A skeleton JUnit test (`src/test/java/seedu/duke/DukeTest.java`) is provided with this project template.
* A skeleton JUnit test (`src/test/java/fittrack/duke/DukeTest.java`) is provided with this project template.
* If you are new to JUnit, refer to the [JUnit Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/junit.html).

## Checkstyle
Expand Down
3 changes: 2 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -42,5 +42,6 @@ checkstyle {
}

run{
enableAssertions = true
standardInput = System.in
}
}
Empty file added data/saveFile.txt
Empty file.
15 changes: 7 additions & 8 deletions docs/AboutUs.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
# About us

Display | Name | Github Profile | Portfolio
--------|:----:|:--------------:|:---------:
![](https://via.placeholder.com/100.png?text=Photo) | John Doe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)
![](https://via.placeholder.com/100.png?text=Photo) | Don Joe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)
![](https://via.placeholder.com/100.png?text=Photo) | Ron John | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)
![](https://via.placeholder.com/100.png?text=Photo) | John Roe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)
![](https://via.placeholder.com/100.png?text=Photo) | Don Roe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)
Display | Name | Github Profile | Portfolio
--------|:----------:|:----------------------------------:|:---------:
![](https://via.placeholder.com/100.png?text=Photo) | Zackermax See Zheng Feng | [Github](https://github.com/Zackermax) | [Portfolio](docs/team/zackermaxsee.md)
![](https://via.placeholder.com/100.png?text=Photo) | Ng Chee Kiang | [Github](https://github.com/CheeKiangg) | [Portfolio](docs/team/CheeKiang.md)
![](https://via.placeholder.com/100.png?text=Photo) | Marcus Wong | [Github](https://github.com/TheDinos) | [Portfolio](docs/team/marcuswong.md)
![](https://via.placeholder.com/100.png?text=Photo) | Avjay Bhar | [Github](https://github.com/Yvorm) | [Portfolio](docs/team/johndoe.md)
![](https://via.placeholder.com/100.png?text=Photo) | Ayushi Yadav | [Github](https://github.com/ayushi0803) | [Portfolio](docs/team/ayushi.md)
6 changes: 6 additions & 0 deletions docs/team/CheeKiang.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Ng Chee Kiang - Project Portfolio Page

## Overview


### Summary of Contributions
2 changes: 1 addition & 1 deletion docs/team/johndoe.md → docs/team/marcuswong.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# John Doe - Project Portfolio Page
# Marcus Wong - Project Portfolio Page

## Overview

Expand Down
6 changes: 6 additions & 0 deletions docs/team/zackermaxsee.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Zackermax See - Project Portfolio Page

## Overview
I am a Year 2 CEG student taking CS2113

### Summary of Contributions
76 changes: 76 additions & 0 deletions src/main/java/fittrack/FitTrack.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
package fittrack;

import java.io.FileNotFoundException;
import java.util.ArrayList;
import java.util.Scanner;

import fittrack.parser.Parser;
import fittrack.trainingsession.TrainingSession;
import fittrack.user.User;

import static fittrack.logger.FitTrackLogger.setupLogger;
import static fittrack.messages.Messages.EXIT_COMMAND;
import static fittrack.storage.Storage.initialiseSaveFile;
import static fittrack.storage.Storage.loadSaveFile;
import static fittrack.ui.Ui.printExitMessage;
import static fittrack.ui.Ui.printGreeting;
import static fittrack.ui.Ui.printUser;

public class FitTrack {
/**
* Main entry-point for the FitTrack CLI application.
*/
public static void main(String[] args) throws FileNotFoundException {
setupLogger();

// Initialize scanner and session list
Scanner scan = new Scanner(System.in);
ArrayList<TrainingSession> sessionList = new ArrayList<>();

// Initialize and load the save file
initialiseSaveFile();
loadSaveFile(sessionList);


// Set user gender and age
printGreeting();
String[] userInfo = scan.nextLine().split(" ", 2);

// Assert user info is valid
assert userInfo.length == 2 : "User info should contain both gender and age";
String gender = userInfo[0];
String age = userInfo[1];

// Assert that age is a valid integer
assert isNumeric(age) : "Age should be a valid integer";

User user = new User(gender, age);
printUser(user);

String input = scan.nextLine();

// Until the exit command is entered, execute command then read user input
while (!input.equals(EXIT_COMMAND)) {
assert !input.trim().isEmpty() : "User input should not be null or empty";
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this supposed to be an assertion or exception?

Parser.parse(user, input, sessionList);
input = scan.nextLine();
}

printExitMessage();
}

/**
* Helper method to check if a string is numeric.
*
* @param str The string to check.
* @return true if the string is numeric, false otherwise.
*/
public static boolean isNumeric(String str) {
try {
Integer.parseInt(str);
return true;
} catch (NumberFormatException e) {
return false;
}
}
}
75 changes: 75 additions & 0 deletions src/main/java/fittrack/calculator/Calculator.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
package fittrack.calculator;

import fittrack.enums.Gender;
import fittrack.exception.InvalidAgeException;
import fittrack.lookupkey.LookUpKey;

import java.util.Comparator;
import java.util.Map;
import java.util.TreeMap;

public abstract class Calculator {

protected static final int AGE_RANGE_LOWER_START = 12;
protected static final int AGE_RANGE_LOWER_END = 19;
protected static final int AGE_RANGE_UPPER_START = 20;
protected static final int AGE_RANGE_UPPER_END = 24;

// Utility method to find the points based on performance in the given table.
protected static int getPointsFromTable(Map<LookUpKey, TreeMap<Integer, Integer>> pointsTable,
Gender gender, int age, int performance, boolean reverseComparison) {

try {
LookUpKey key = new LookUpKey(gender, age);
TreeMap<Integer, Integer> subTable = pointsTable.get(key);

for (Map.Entry<Integer, Integer> entry : subTable.entrySet()) {
if ((reverseComparison && performance <= entry.getKey()) ||
(!reverseComparison && performance >= entry.getKey())) {
return entry.getValue();
}
}
return 0; // return 0 points as performance is below the minimum standard
} catch (InvalidAgeException e) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the variable name "e" informative enough?

System.out.println(e.getMessage());
return 0; // return 0 points as invalid age is inputted
}
}

// Utility method to add age sub-table for a specific gender
protected static void addAgeSubTable(Map<LookUpKey, TreeMap<Integer, Integer>> pointsTable,
Gender gender, int age, int[][] points, boolean reverseOrder) {
assert age >= 12 && age <= 24 : "Age should be within 12 and 24 during table initialisation"; //
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Accidental empty comment?

TreeMap<Integer, Integer> ageSubTable;
if (reverseOrder){
ageSubTable = new TreeMap<>(Comparator.reverseOrder());
} else{
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Java reserved words should be followed by a white space

ageSubTable = new TreeMap<>();
}

for (int[] point : points) {
assert point[0] >= 0 : "Performance metric cannot be negative";
assert point[1] >= 0 : "Points should never be negative";
ageSubTable.put(point[0], point[1]);
}

try {
pointsTable.put(new LookUpKey(gender, age), ageSubTable);
} catch (InvalidAgeException e) {
System.out.println(e.getMessage());;
}
}

protected static void addAllTables(Map<LookUpKey, TreeMap<Integer, Integer>> pullUpTable,
Gender gender, int[][][] ageTables, boolean reverseOrder) {
// Add data for lower ages
for (int age = AGE_RANGE_LOWER_START; age <= AGE_RANGE_LOWER_END; age++) {
addAgeSubTable(pullUpTable, gender, age, ageTables[age - AGE_RANGE_LOWER_START], reverseOrder);
}

// Add data for upper ages
for (int age = AGE_RANGE_UPPER_START; age <= AGE_RANGE_UPPER_END; age++) {
addAgeSubTable(pullUpTable, gender, age, ageTables[ageTables.length - 1], reverseOrder); // Age 20-24 table
}
}
}
53 changes: 53 additions & 0 deletions src/main/java/fittrack/calculator/PullUpCalculator.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
package fittrack.calculator;

import fittrack.enums.Gender;
import fittrack.lookupkey.LookUpKey;

import java.util.HashMap;
import java.util.Map;
import java.util.TreeMap;

public class PullUpCalculator extends Calculator {
private static final Map<LookUpKey, TreeMap<Integer, Integer>> pullUpTable = new HashMap<>();
private static final boolean reverseOrder = true;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Constant names must be all uppercase using underscore to separate words


static {
initialiseMaleData();
initialiseFemaleData();
}

public static int calculatePoints(Gender gender, int age, int reps) {
return getPointsFromTable(pullUpTable, gender, age, reps, false);
}

private static void initialiseMaleData() {
// Age data arrays
int[][][] ageTables = {
{{25, 5}, {21, 4}, {16, 3}, {11, 2}, {5, 1}},
{{26, 5}, {22, 4}, {17, 3}, {12, 2}, {7, 1}},
{{27, 5}, {23, 4}, {18, 3}, {13, 2}, {8, 1}},
{{8, 5}, {6, 4}, {5, 3}, {3, 2}, {1, 1}},
{{9, 5}, {7, 4}, {5, 3}, {3, 2}, {1, 1}},
{{10, 5}, {8, 4}, {6, 3}, {4, 2}, {2, 1}},
{{11, 5}, {9, 4}, {7, 3}, {5, 2}, {3, 1}},
{{11, 5}, {9, 4}, {7, 3}, {5, 2}, {3, 1}},
{{11, 5}, {9, 4}, {7, 3}, {5, 2}, {3, 1}}
};
addAllTables(pullUpTable, Gender.MALE, ageTables, reverseOrder);
}

private static void initialiseFemaleData() {
int[][][] ageTables = {
{{16, 5}, {13, 4}, {10, 3}, {7, 2}, {3, 1}},
{{17, 5}, {13, 4}, {10, 3}, {7, 2}, {3, 1}},
{{17, 5}, {14, 4}, {10, 3}, {7, 2}, {3, 1}},
{{17, 5}, {14, 4}, {10, 3}, {7, 2}, {3, 1}},
{{18, 5}, {14, 4}, {11, 3}, {7, 2}, {3, 1}},
{{18, 5}, {14, 4}, {11, 3}, {7, 2}, {3, 1}},
{{18, 5}, {15, 4}, {11, 3}, {8, 2}, {4, 1}},
{{18, 5}, {15, 4}, {11, 3}, {8, 2}, {5, 1}},
{{18, 5}, {15, 4}, {11, 3}, {8, 2}, {5, 1}}
};
addAllTables(pullUpTable, Gender.FEMALE, ageTables, reverseOrder);
}
}
56 changes: 56 additions & 0 deletions src/main/java/fittrack/calculator/ShuttleRunCalculator.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
package fittrack.calculator;

import fittrack.enums.Gender;
import fittrack.lookupkey.LookUpKey;
import java.util.HashMap;
import java.util.Map;
import java.util.TreeMap;

public class ShuttleRunCalculator extends Calculator {
private static final Map<LookUpKey, TreeMap<Integer, Integer>> shuttleRunTable = new HashMap<>();
private static final boolean reverseOrder = false;

static {
initialiseMaleData();
initialiseFemaleData();
}

public static int calculatePoints(Gender gender, int age, int reps) {
assert ((age >= AGE_RANGE_LOWER_START) && (age <= AGE_RANGE_UPPER_END));
return getPointsFromTable(shuttleRunTable, gender, age, reps, true);
}

// Shuttle Run time (in hundredths of seconds)
private static void initialiseMaleData() {
// Age data arrays
int[][][] ageTables = {
{{103, 5}, {109, 4}, {113, 3}, {117, 2}, {122, 1}}, // Age 12
{{102, 5}, {107, 4}, {111, 3}, {115, 2}, {119, 1}}, // Age 13
{{101, 5}, {104, 4}, {108, 3}, {112, 2}, {116, 1}}, // Age 14
{{101, 5}, {103, 4}, {105, 3}, {109, 2}, {113, 1}}, // Age 15
{{101, 5}, {103, 4}, {105, 3}, {107, 2}, {111, 1}}, // Age 16
{{101, 5}, {103, 4}, {105, 3}, {107, 2}, {109, 1}}, // Age 17
{{101, 5}, {103, 4}, {105, 3}, {107, 2}, {109, 1}}, // Age 18
{{101, 5}, {103, 4}, {105, 3}, {107, 2}, {109, 1}}, // Age 19
{{103, 5}, {105, 4}, {107, 3}, {109, 2}, {111, 1}} // Age 20-24
};
addAllTables(shuttleRunTable, Gender.MALE, ageTables, reverseOrder);
}

private static void initialiseFemaleData() {

// Age data arrays
int[][][] ageTables = {
{{114, 5}, {119, 4}, {123, 3}, {127, 2}, {132, 1}}, // Age 12
{{112, 5}, {117, 4}, {122, 3}, {127, 2}, {132, 1}}, // Age 13
{{114, 5}, {118, 4}, {122, 3}, {126, 2}, {130, 1}}, // Age 14
{{112, 5}, {116, 4}, {120, 3}, {124, 2}, {128, 1}}, // Age 15
{{112, 5}, {115, 4}, {118, 3}, {122, 2}, {126, 1}}, // Age 16
{{112, 5}, {115, 4}, {118, 3}, {121, 2}, {125, 1}}, // Age 17
{{112, 5}, {115, 4}, {118, 3}, {121, 2}, {124, 1}}, // Age 18
{{112, 5}, {115, 4}, {118, 3}, {121, 2}, {124, 1}}, // Age 19
{{115, 5}, {118, 4}, {121, 3}, {124, 2}, {127, 1}} // Age 20-24
};
addAllTables(shuttleRunTable, Gender.FEMALE, ageTables, reverseOrder);
}
}
52 changes: 52 additions & 0 deletions src/main/java/fittrack/calculator/SitAndReachCalculator.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
package fittrack.calculator;

import fittrack.enums.Gender;
import fittrack.lookupkey.LookUpKey;

import java.util.HashMap;
import java.util.Map;
import java.util.TreeMap;

public class SitAndReachCalculator extends Calculator {
private static final Map<LookUpKey, TreeMap<Integer, Integer>> sitAndReachTable = new HashMap<>();
private static final boolean reverseOrder = true;

static {
initialiseMaleData();
initialiseFemaleData();
}

public static int calculatePoints(Gender gender, int age, int length) {
return getPointsFromTable(sitAndReachTable, gender, age, length, false);
}

private static void initialiseMaleData() {
int[][][] ageTables = {
{{40, 5}, {36, 4}, {32, 3}, {28, 2}, {23, 1}},
{{42, 5}, {38, 4}, {34, 3}, {30, 2}, {25, 1}},
{{44, 5}, {40, 4}, {36, 3}, {31, 2}, {27, 1}},
{{46, 5}, {42, 4}, {38, 3}, {33, 2}, {29, 1}},
{{48, 5}, {44, 4}, {40, 3}, {36, 2}, {31, 1}},
{{49, 5}, {45, 4}, {41, 3}, {36, 2}, {32, 1}},
{{49, 5}, {45, 4}, {41, 3}, {37, 2}, {32, 1}},
{{49, 5}, {45, 4}, {41, 3}, {37, 2}, {32, 1}},
{{48, 5}, {44, 4}, {40, 3}, {36, 2}, {32, 1}}
};
addAllTables(sitAndReachTable, Gender.MALE, ageTables, reverseOrder);
}

private static void initialiseFemaleData() {
int[][][] ageTables = {
{{40, 5}, {37, 4}, {34, 3}, {30, 2}, {25, 1}},
{{42, 5}, {38, 4}, {36, 3}, {32, 2}, {27, 1}},
{{44, 5}, {41, 4}, {38, 3}, {33, 2}, {29, 1}},
{{46, 5}, {43, 4}, {39, 3}, {35, 2}, {31, 1}},
{{47, 5}, {44, 4}, {40, 3}, {36, 2}, {31, 1}},
{{47, 5}, {44, 4}, {41, 3}, {36, 2}, {32, 1}},
{{47, 5}, {44, 4}, {41, 3}, {36, 2}, {32, 1}},
{{47, 5}, {44, 4}, {41, 3}, {36, 2}, {32, 1}},
{{44, 5}, {41, 4}, {38, 3}, {35, 2}, {31, 1}}
};
addAllTables(sitAndReachTable, Gender.FEMALE, ageTables, reverseOrder);
}
}
Loading
Loading