Git-Leon c60b137cea Update README.md | 6 anni fa | |
---|---|---|
src | 6 anni fa | |
.gitignore | 6 anni fa | |
README.md | 6 anni fa | |
pom.xml | 6 anni fa |
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