Skip to content

Conversation

@PiotrHic
Copy link

My V1 of the task

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.

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.

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.

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.

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.

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.

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.

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.

Copy link

@slade13 slade13 left a 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....");
Copy link

Choose a reason for hiding this comment

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

Suggested change
System.out.println("Track starts wrrrr....");
System.out.println("Truck starts wrrrr....");


@Override
public void stopWork() {
System.out.println("Track stops....");
Copy link

Choose a reason for hiding this comment

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

Suggested change
System.out.println("Track stops....");
System.out.println("Truck stops....");

public class Excavator extends Machine {
@Override
public void doWork() {
System.out.println("Excavatore starts...");
Copy link

Choose a reason for hiding this comment

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

Suggested change
System.out.println("Excavatore starts...");
System.out.println("Excavator starts...");


@Override
public void stopWork() {
System.out.println("Excavatore stops...");
Copy link

Choose a reason for hiding this comment

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

Suggested change
System.out.println("Excavatore stops...");
System.out.println("Excavator stops...");


@Override
public void doWork() {
System.out.println("Bulldozer starts.....");
Copy link

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....");
Copy link

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 {

Copy link

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 {

Copy link

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()};
Copy link

Choose a reason for hiding this comment

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

Conventional style is:

Suggested change
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) {
Copy link

Choose a reason for hiding this comment

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

Enhanced for-loop spacing:

Suggested change
for (Machine machine: machines) {
for (Machine machine : machines) {

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.

3 participants