|
@@ -0,0 +1,29 @@
|
|
1
|
+# Froilan The Farmer
|
|
2
|
+* **Objective:** To implement a system indicative of a Farm environment
|
|
3
|
+* **Purpose:** To demonstrate [multi-inheritence design issues](https://www.geeksforgeeks.org/java-and-multiple-inheritance/)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+* Consider a system in which
|
|
7
|
+ * All `NoiseMaker` can `makeNoise`
|
|
8
|
+ * All `Animal` are `NoiseMaker`
|
|
9
|
+ * All `Horse` are `Animal`
|
|
10
|
+ * All `Dog` are `Animal`
|
|
11
|
+
|
|
12
|
+ * All `Rider` can `mount` and `dismount` a `Rideable` object.
|
|
13
|
+
|
|
14
|
+ * All `Vehicle` are `NoiseMaker` and `Rideable`
|
|
15
|
+ * All `FarmVehicle` can `harvest` a `Produce`
|
|
16
|
+ * All `Tractor` are `FarmVehicle`
|
|
17
|
+ * All `CropDuster` are `FarmVehicle`
|
|
18
|
+
|
|
19
|
+ * All `Aircraft` can `fly`
|
|
20
|
+ * All `Plane` are `Aircraft` which can `cruise`
|
|
21
|
+ * All `Jet` are `Aircraft` which can `zoom`
|
|
22
|
+
|
|
23
|
+ * All `Produce` can `yield` an `Edible` object.
|
|
24
|
+ * All `CornStalk` can `yield` a `EarCorn`
|
|
25
|
+ * All `TomatoPlant` can `yield` a `Tomato`
|
|
26
|
+
|
|
27
|
+ * All `Person` can `eat` an `Edible` object and `makeNoise`.
|
|
28
|
+ * All `Farmer` are `Rider` and `Person`
|
|
29
|
+ * `Froilan` is a `Farmer` who has
|