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

Implement Presentation Model Pattern #1710

Merged
merged 45 commits into from
May 11, 2021
Merged

Implement Presentation Model Pattern #1710

merged 45 commits into from
May 11, 2021

Conversation

EdisonE3
Copy link
Contributor

Presentation Model Pattern
-Implemented Registry pattern addressing the issue #415

Description
-Represent the state and behavior of the presentation independently of the GUI controls used in the interface

@EdisonE3 EdisonE3 closed this Apr 22, 2021
@EdisonE3 EdisonE3 reopened this Apr 22, 2021
@EdisonE3 EdisonE3 closed this Apr 22, 2021
@EdisonE3 EdisonE3 reopened this Apr 22, 2021
@EdisonE3 EdisonE3 closed this Apr 22, 2021
@EdisonE3 EdisonE3 reopened this Apr 22, 2021
@EdisonE3 EdisonE3 closed this Apr 22, 2021
@EdisonE3 EdisonE3 reopened this Apr 22, 2021
@EdisonE3 EdisonE3 closed this Apr 22, 2021
@EdisonE3 EdisonE3 reopened this Apr 22, 2021
@ohbus ohbus linked an issue Apr 22, 2021 that may be closed by this pull request
@ohbus ohbus self-assigned this Apr 22, 2021
Copy link
Contributor

@ohbus ohbus left a comment

Choose a reason for hiding this comment

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

Thank you so much @EdisonE3 for your valuable contribution!

Please take a note of the following points:

  • Increase Code Coverage try making it to 100%
  • Use Logger to show some verbose logging of the work that is being done. Take a look at other implemented patterns to get an idea.
  • Remove the Code Smells as reported by Sonar, let us know if there are any false positives.

Good Luck 👍🏻

Comment on lines 3 to 7
/**
*A class used to store the information of album.
*
* @author EdisonE3
*/
Copy link
Contributor

Choose a reason for hiding this comment

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

Remove the author tag

Comment on lines 15 to 30
/**
* The constructor method of Album.
*
* @param rowId the id of the album
* @param title the title of the album
* @param artist the name of artist
* @param isClassical whether the album is classical
* @param composer the name of composer
*/
public Album(int rowId, String title, String artist, boolean isClassical, String composer) {
this.rowId = rowId;
this.title = title;
this.artist = artist;
this.isClassical = isClassical;
this.composer = composer;
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Use lombok for boilerplate code

Comment on lines 3 to 7
/**
* a class used to start this demo.
*
* @author EdisonE3
*/
Copy link
Contributor

Choose a reason for hiding this comment

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

remove author tag

Comment on lines 6 to 10
/**
* a class used to deal with albums.
*
* @author EdisonE3
*/
Copy link
Contributor

Choose a reason for hiding this comment

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

remove author tag

Comment on lines 3 to 7
/**
* The class between view and albums, it is used to control the data.
*
* @author EdisonE3
*/
Copy link
Contributor

Choose a reason for hiding this comment

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

remove the author tag

Comment on lines 87 to 89



Copy link
Contributor

Choose a reason for hiding this comment

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

remove extra spaces

Comment on lines 14 to 18
/**
* Generates the GUI of albums.
*
* @author EdisonE3
*/
Copy link
Contributor

Choose a reason for hiding this comment

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

remove the author tag

@EdisonE3
Copy link
Contributor Author

Thanks a lot!
I will update this as soon as possible. @ohbus

presentation/README.md Show resolved Hide resolved
@EdisonE3 EdisonE3 requested a review from ohbus April 26, 2021 12:09
presentation/README.md Show resolved Hide resolved
presentation/README.md Show resolved Hide resolved
presentation/README.md Show resolved Hide resolved
presentation/pom.xml Outdated Show resolved Hide resolved
Comment on lines 71 to 78
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-pmd-plugin</artifactId>
<configuration>
<linkXRef>false</linkXRef>
</configuration>
<version>3.14.0</version>
</plugin>
Copy link
Owner

Choose a reason for hiding this comment

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

Not needed, we use SonarCloud for static analysis

presentation/README.md Outdated Show resolved Hide resolved
presentation/README.md Outdated Show resolved Hide resolved
@EdisonE3
Copy link
Contributor Author

EdisonE3 commented May 2, 2021

Thanks for your advices, I will try to make it better.

@EdisonE3 EdisonE3 requested a review from iluwatar May 3, 2021 07:09
@EdisonE3
Copy link
Contributor Author

EdisonE3 commented May 7, 2021

Hello, the changes requested have been finished. @ohbus

iluwatar
iluwatar previously approved these changes May 9, 2021
Copy link
Owner

@iluwatar iluwatar left a comment

Choose a reason for hiding this comment

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

Looks good to me. @ohbus can merge once all the comments have been resolved.

Copy link
Contributor

@ohbus ohbus left a comment

Choose a reason for hiding this comment

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

LGTM.

Thank you so much for your contribution @EdisonE3

@sonarcloud
Copy link

sonarcloud bot commented May 11, 2021

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

88.2% 88.2% Coverage
0.0% 0.0% Duplication

@ohbus ohbus added this to the 1.25.0 milestone May 11, 2021
@ohbus ohbus merged commit f1feb3f into iluwatar:master May 11, 2021
@ohbus
Copy link
Contributor

ohbus commented May 11, 2021

@all-contributors please add @EdisonE3 for code

@allcontributors
Copy link
Contributor

@ohbus

I've put up a pull request to add @EdisonE3! 🎉

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

Successfully merging this pull request may close these issues.

Presentation Model pattern
3 participants