-
Notifications
You must be signed in to change notification settings - Fork 17
Homework ;) #5
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
base: master
Are you sure you want to change the base?
Homework ;) #5
Conversation
alexanderko
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Хорошо 🔥
|
|
||
| @Override | ||
| public boolean inCondition(Check check) { | ||
| return check.getCostByCategory(category) > 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
extract amount into field
| } | ||
|
|
||
| @Override | ||
| public boolean inCondition(Check check) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
chose better method name
| @@ -1,5 +1,10 @@ | |||
| package checkout; | |||
|
|
|||
| import java.util.Date; | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use LocalDate from java.time
| this.category = category; | ||
| } | ||
|
|
||
| public Product(int price, String name, Category category, Trademark trademark) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
constructor duplication
|
|
||
| import java.util.Date; | ||
|
|
||
| public class SuperOffer extends Offer { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
make Offer concrete class
Attempt to realize all points