-
Notifications
You must be signed in to change notification settings - Fork 1.8k
V1 #2470
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?
V1 #2470
Conversation
mateacademy-ai-mentor
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.
Sorry, the pull request review was unsuccessful for the following reasons:
Warning
The test task has already been approved.
[CODE: AAP]
If the issue is within your control, please address it.
The next review attempt will automatically launch in about 1 hour.
If you believe this is an error or need assistance, please contact the support team.
mateacademy-ai-mentor
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.
Sorry, the pull request review was unsuccessful for the following reasons:
Warning
The test task has already been approved.
[CODE: AAP]
If the issue is within your control, please address it.
The next review attempt will automatically launch in about 1 hour.
If you believe this is an error or need assistance, please contact the support team.
mateacademy-ai-mentor
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.
Sorry, the pull request review was unsuccessful for the following reasons:
Warning
The test task has already been approved.
[CODE: AAP]
If the issue is within your control, please address it.
The next review attempt will automatically launch in about 1 hour.
If you believe this is an error or need assistance, please contact the support team.
mateacademy-ai-mentor
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.
Sorry, the pull request review was unsuccessful for the following reasons:
Warning
The test task has already been approved.
[CODE: AAP]
If the issue is within your control, please address it.
The next review attempt will automatically launch in about 1 hour.
If you believe this is an error or need assistance, please contact the support team.
slade13
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.
Please fix those minor problems and send your task again for a review.
There are too many commits as for such simple task, there could be one commit called:
feat(oop): implement Machine hierarchy and demo polymorphism
For each added class you've added single commit.
This commit has a typo: Trock Class -> 'Truck Class' -> but still it does not say anything about what was done. Was it changed/added/removed? Commi messages should be informative.
This one is also bad: src/main/java/core/basesyntax/Excavator.java
And this one is so general that it doesn't have any sense: Final commit
Start you commit messages lowercase, use informative messages, for example you have to add service implementation for car rental app:
`add implementation for car rental system service' -> lowercase, informative and says what was done there.
Inside commit messages you can also add description which will be more detailed.
|
|
||
| @Override | ||
| public void doWork() { | ||
| System.out.println("Track starts wrrrr...."); |
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.
| System.out.println("Track starts wrrrr...."); | |
| System.out.println("Truck starts wrrrr...."); |
|
|
||
| @Override | ||
| public void stopWork() { | ||
| System.out.println("Track stops...."); |
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.
| System.out.println("Track stops...."); | |
| System.out.println("Truck stops...."); |
| public class Excavator extends Machine { | ||
| @Override | ||
| public void doWork() { | ||
| System.out.println("Excavatore starts..."); |
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.
| System.out.println("Excavatore starts..."); | |
| System.out.println("Excavator starts..."); |
|
|
||
| @Override | ||
| public void stopWork() { | ||
| System.out.println("Excavatore stops..."); |
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.
| System.out.println("Excavatore stops..."); | |
| System.out.println("Excavator stops..."); |
|
|
||
| @Override | ||
| public void doWork() { | ||
| System.out.println("Bulldozer starts....."); |
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.
Messages like "....."/"wrrrr" are noisy; the checklist asks for informative messages.
|
|
||
| @Override | ||
| public void stopWork() { | ||
| System.out.println("Track stops...."); |
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.
Messages like "....."/"wrrrr" are noisy; the checklist asks for informative messages.
| package core.basesyntax; | ||
|
|
||
| public class Bulldozer extends Machine { | ||
|
|
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.
Remove this redundant empty line.
| package core.basesyntax; | ||
|
|
||
| public class Truck extends Machine { | ||
|
|
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.
Remove this redundant empty line.
| public class MainApp { | ||
|
|
||
| public static void main(String[] args) { | ||
| Machine [] machines = new Machine[]{new Truck(), new Excavator(), new Bulldozer()}; |
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.
Conventional style is:
| Machine [] machines = new Machine[]{new Truck(), new Excavator(), new Bulldozer()}; | |
| Machine[] machines = new Machine[] {new Truck(), new Excavator(), new Bulldozer()}; |
|
|
||
| public static void main(String[] args) { | ||
| Machine [] machines = new Machine[]{new Truck(), new Excavator(), new Bulldozer()}; | ||
| for (Machine machine: machines) { |
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.
Enhanced for-loop spacing:
| for (Machine machine: machines) { | |
| for (Machine machine : machines) { |
My V1 of the task