Skip to content

Releases: sashaNull/project2024

v3.1

Choose a tag to compare

@sashaNull sashaNull released this 10 Jul 06:57

Restore removed functions in the UI

v3

v3

Choose a tag to compare

@rmetzman rmetzman released this 01 Jul 14:15
9444dfa
Add files via upload

v2.1

Choose a tag to compare

@rmetzman rmetzman released this 25 Jun 18:54
e9faea4
Update UserInterface.java to undo overwriting

v2

v2

Choose a tag to compare

@rmetzman rmetzman released this 20 Jun 02:16
78e17b0

Phase 2 Writeup

Team Members:

  • Sasha Nguyen
  • Matthieu Perez
  • Rebecca Metzman

Additional Tasks for Grading

In addition to implementing the tasks described above, your team should also write a brief report that includes the following:
The Additional Tasks that you would like graded for this phase. Please keep in mind that we will only grade three Additional Tasks for a group of three, and four Additional Tasks for a group of four. If you list more than that, the tasks that get graded will be decided at the grader’s discretion.

  • 2.6
  • 2.8
  • 2.11 (1.10)

Changes Made to the Provided Code

2.1

Implemented a caching mechanism in the getContributorName method by adding a new private Map<String, String> contributorNameCache. The cache improves performance by storing previously retrieved contributor names, reducing the need for repeated network calls.

2.2

  • Added validation checks to ensure that the WebClient, login, and password parameters are not null.
  • Added error handling for cases when the WebClient cannot connect to the server, returns null, or provides malformed JSON data.
  • Updated methods to throw IllegalStateException or IllegalArgumentException where appropriate to match the test cases.
  • UserInterface Class: Updated the start, createFund, and main methods to handle exceptions.

2.3

  • Added the class ContributorAggregate.java to deal with aggregating donations.
  • Added a displayAggregatedDonation method to the UI class.
  • Added an aggregatedDonations cache to store the aggregated donations.

2.6

  • Added the method getAggregatedDonations() to aggregate donations by fund, cache the results, and order them by total donation amount in descending order.
  • Updated the onResume() method.
  • Created a new class to hold aggregate data for donations.

2.8

  • Improved user prompts for commands like logging out.
  • Added new methods for managing user sessions effectively.

2.11 (1.10)

  • Added a DateTimeFormatter field called formatter to change the format of the date displayed.

Known Bugs or Issues

List any known bugs or issues with the tasks you attempted in this phase.

Instructions

Instructions on how to start each app, if you changed anything from the original version of the code, e.g. the name of the Java main class or JavaScript entry point, arguments to the programs, etc. If you did not change anything, you may omit this.

Team Member Contributions

  • Rebecca Metzman: Worked on 2.3 and 2.11 (which we did 1.10 for).
  • Sasha Nguyen: Worked on 2.1 and 2.8.
  • Matthieu Perez: Worked on 2.2 and 2.6.

The writeup should be committed to your GitHub repo as a plain-text or .md file named “Phase 2 writeup” by the deadline stated above.

v1

v1

Choose a tag to compare

@rmetzman rmetzman released this 11 Jun 22:10
a019f45

Group 10

Team Members:

  • Rebecca Metzman
  • Sasha Nguyen
  • Matthieu Perez

Additional Tasks:

  • 1.5
  • 1.8
  • 1.9

Descriptions of Changes:

1.1

  • Added test cases / new test classes for the other methods.

1.2

  • NA

1.3

  • Changed the start function.

1.4

  • Added a new variable to calculate the total amount of donations and display it.

1.5

  • Added test cases / new test files for each method.

1.8

  • Changed the createFund method.

1.9

  • Made attemptLogin throw an IllegalStateException and added a try-catch block in the main() function of UI.

Bugs Found and Fixed:

1.5:

  • Changed from direct get method calls in attemptLogin to optString and optInt methods to safely retrieve values from the JSON object. This resolves the issue where the method was expected to handle missing fields gracefully but did not do so.
  • Added a catch block specifically for JSONException to handle invalid JSON responses better. When a JSONException is caught, the method now returns null instead of propagating the exception.
  • In getFundName, added a check to verify if the response is a valid JSON object before attempting to parse it. If the response is not valid JSON, the method now handles it appropriately by logging the error and returning null.
  • In getAllOrganizations, added a check to verify if the response is a valid JSON object before attempting to parse it. This helps handle cases where the response is not valid JSON, preventing the JSONException.
  • In makeDonation, added a check to verify if the response is a valid JSON object before attempting to parse it.

Known Bugs or Issues:

  • (Include any known bugs or issues here if applicable)

Instructions:

  • (Include instructions on how to start each app, if anything was changed from the original version of the code. If nothing was changed, this section can be omitted.)

Team Member Contributions:

Rebecca Metzman

  • Tasks: 1.1, 1.2, 1.5

Sasha Nguyen

  • Tasks: 1.4, 1.9

Matthieu Perez

  • Tasks: 1.3, 1.8