Git-Leon c60b137cea Update README.md | пре 6 година | |
---|---|---|
src | пре 6 година | |
.gitignore | пре 6 година | |
README.md | пре 6 година | |
pom.xml | пре 6 година |
Purpose: To demonstrate multi-inheritence design issues
Consider a system in which
NoiseMaker
can makeNoise
All Animal
are NoiseMaker
Horse
are Animal
Dog
are Animal
All Rider
can mount
and dismount
a Rideable
object.
All Vehicle
are NoiseMaker
and Rideable
All FarmVehicle
can harvest
a Produce
Tractor
are FarmVehicle
CropDuster
are FarmVehicle
All Aircraft
can fly
Plane
are Aircraft
which can cruise
Jet
are Aircraft
which can zoom
All Produce
can yield
an Edible
object.
CornStalk
can yield
a EarCorn
TomatoPlant
can yield
a Tomato
All Person
can eat
an Edible
object and makeNoise
.
All Farmer
are Rider
and Person
Froilan
is a Farmer
who has