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

Implements MovieRecommender class #72

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open

Implements MovieRecommender class #72

wants to merge 7 commits into from

Conversation

ghost
Copy link

@ghost ghost commented Oct 7, 2019

Test completed sucessfully.

<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>21.0</version>
Copy link

Choose a reason for hiding this comment

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

move version to properties

* Generates a .csv file with the relevant information in the correct format.
* Loads the users, products and reviews info.
*/
public void readFile() {
Copy link

Choose a reason for hiding this comment

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

You're mixing responsibilities in this class, I recommend to split into 3 classes:

  • One to represent your data that only has setters and getters
  • One that take cares of the translation of the input file to the csv file. This class does not need to have a state, the input file and the output file can be provided in the method processing the input.
  • One that uses the first one and provides the method getRecommendationsForUser

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant