generated from mate-academy/jv-homework-template
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Created class Machine containing methods public abstract void doWork(…
…) and public abstract void stopWork(). Add classes Truck, Bulldozer, Excavator that will inherit from Machine and override doWork() and stopWork() methods. In Main class was created Machine array with Truck, Buldozer and Excavator and call methods doWork() and stopWork() in a loop.
- Loading branch information
1 parent
278ba17
commit 2970b99
Showing
5 changed files
with
0 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
package core.basesyntax; | ||
|
||
public class Buldozer extends Machine{ | ||
@Override | ||
public void doWork() { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
package core.basesyntax; | ||
|
||
public class Excavator extends Machine { | ||
@Override | ||
public void doWork() { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
package core.basesyntax; | ||
|
||
public class Truck extends Machine{ | ||
@Override | ||
public void doWork() { | ||
|