| 1 | package Question3_7; |
| 2 | |
| 3 | public abstract class Animal { |
| 4 | private int order; |
| 5 | protected String name; |
| 6 | public Animal(String n) { |
| 7 | name = n; |
| 8 | } |
| 9 | |
| 10 | public abstract String name(); |
| 11 | |
| 12 | public void setOrder(int ord) { |
| 13 | order = ord; |
| 14 | } |
| 15 | |
| 16 | public int getOrder() { |
| 17 | return order; |
| 18 | } |
| 19 | |
| 20 | public boolean isOlderThan(Animal a) { |
| 21 | return this.order < a.getOrder(); |
| 22 | } |
| 23 | } |
nothing calls this directly
no outgoing calls
no test coverage detected