-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
first try #1595
base: master
Are you sure you want to change the base?
first try #1595
Conversation
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.
Good job! Let’s fix some minor mistakes
README.md
Outdated
- Create class core.basesyntax.Machine containing methods `public abstract void doWork()` and `public abstract void stopWork()`. | ||
- Create classes `core.basesyntax.Truck`, `core.basesyntax.Bulldozer`, `core.basesyntax.Excavator` that will inherit from `core.basesyntax.Machine`. | ||
- In those classes override `doWork()`, so it will print message that certain machine started its work. | ||
- Override `stopWork()` as well. It should print messages that certain machine stopped its work. | ||
- In `MainApp` class create `Machine` array with `Truck`, `Bulldozer` and `Excavator` and call methods `doWork()` and `stopWork()` in a loop. | ||
- In `MainApp` class create `core.basesyntax.Machine` array with `core.basesyntax.Truck`, `core.basesyntax.Bulldozer` and `core.basesyntax.Excavator` and call methods `doWork()` and `stopWork()` in a loop. |
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.
You don’t need to change README file. Let’s revert the changes.
checklist.md
Outdated
message should indicate what type of `core.basesyntax.Machine` is working right now `core.basesyntax.Truck`, `core.basesyntax.Bulldozer` or `core.basesyntax.Excavator`. | ||
|
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.
the same here
|
||
public class Bulldozer extends Machine { | ||
public void doWork() { | ||
System.out.println("core.basesyntax.Bulldozer started its work"); |
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.
Don’t use package names in messages. Let’s remove it everywhere
public void stopWork() { | ||
System.out.println("core.basesyntax.Bulldozer stoped its work"); | ||
} | ||
|
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.
Redundant empty line
package core.basesyntax; | ||
|
||
public class Excavator 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.
Redundant empty line
public class Truck extends Machine { | ||
|
||
public void doWork() { | ||
|
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.
Redundant empty line
public void stopWork() { | ||
System.out.println("core.basesyntax.Truck stoped its work"); | ||
} | ||
|
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.
Redundant empty line
No description provided.