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

add_home_work_advanced_oop #1781

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

Conversation

DenDy1227
Copy link

***homeWork : advanced-oop

result output
image

Copy link

@mateacademy-ai-mentor mateacademy-ai-mentor 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 for your hard work on this project! While your implementation is mostly correct, there are a few critical issues that need to be addressed before we can approve the pull request:

  1. Interface Naming: The interface Drowable is misspelled and should be corrected to Drawable. This is important for maintaining clarity and consistency in your codebase.

  2. Enum Constant Access: Throughout your code, ensure that you use the name() method to access enum constants (e.g., Figures.Circle.name()). This prevents potential issues if toString() is overridden in the enum class.

  3. Redundant Code: In the Square class, the call to this.setColor(color); is redundant because the superclass constructor already sets the color. Removing unnecessary code helps keep your implementation clean and efficient.

These changes are essential to ensure that your code functions as expected and adheres to the task requirements. Once you've made these adjustments, feel free to resubmit your pull request. Keep up the great work, and don't hesitate to reach out if you have any questions or need further assistance! 😊

✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨

🔄 Fix the issues, commit the changes, and then re-request my review using the Re-request review button in the Reviewers tab.

src/main/java/classes_inheritors/Circle.java Outdated Show resolved Hide resolved
src/main/java/classes_inheritors/Circle.java Outdated Show resolved Hide resolved
src/main/java/classes_inheritors/Drowable.java Outdated Show resolved Hide resolved
src/main/java/classes_inheritors/Figure.java Outdated Show resolved Hide resolved
src/main/java/classes_inheritors/FigureSupplier.java Outdated Show resolved Hide resolved
src/main/java/classes_inheritors/IsoscelesTrapezoid.java Outdated Show resolved Hide resolved
src/main/java/classes_inheritors/Rectangle.java Outdated Show resolved Hide resolved
src/main/java/classes_inheritors/RightTriangle.java Outdated Show resolved Hide resolved
src/main/java/classes_inheritors/Square.java Outdated Show resolved Hide resolved
src/main/java/classes_inheritors/Square.java Outdated Show resolved Hide resolved
Copy link

@mateacademy-ai-mentor mateacademy-ai-mentor 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 for your hard work on this project! 🎉 Your implementation is mostly correct, but there are a few critical issues that need attention:

  1. Interface Naming: The interface Drowable is misspelled and should be corrected to Drawable to maintain clarity and consistency in your codebase.

  2. Enum Constant Access: In the draw() methods of the Rectangle, Circle, RightTriangle, Square, and IsoscelesTrapezoid classes, consider using Figures.<Enum>.name() instead of directly accessing the enum constants. This ensures consistency and avoids potential issues if toString() is overridden.

  3. Redundant Code: In the Square class, the call to this.setColor(color); is redundant because the superclass constructor already sets the color. Consider removing this line to avoid unnecessary code.

  4. Measurement Units: Ensure that linear measurements like radius, side, firstLeg, secondLeg, width, height, baseTop, and baseBottom are not labeled as 'sq. units'. They should be labeled as 'units' since they are linear measurements, not areas.

These changes are essential to ensure that your code functions as expected and adheres to the task requirements. The decision to approve is made to help you move forward with your learning. Please review the comments and improve your code accordingly. Keep up the great work and continue learning from these experiences! 🚀

✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨

src/main/java/classes/Circle.java Outdated Show resolved Hide resolved
src/main/java/classes/Circle.java Show resolved Hide resolved
src/main/java/classes/Drowable.java Outdated Show resolved Hide resolved
src/main/java/classes/Figure.java Outdated Show resolved Hide resolved
src/main/java/classes/FigureSupplier.java Outdated Show resolved Hide resolved
src/main/java/classes/RightTriangle.java Outdated Show resolved Hide resolved
src/main/java/classes/RightTriangle.java Outdated Show resolved Hide resolved
src/main/java/classes/Square.java Outdated Show resolved Hide resolved
src/main/java/classes/Square.java Outdated Show resolved Hide resolved
src/main/java/classes/Square.java Show resolved Hide resolved
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.

2 participants