Class Human
java.lang.Object
|
+--Animal
|
+--Human
- public class Human
- extends Animal
Class Human - write a description of the class here
Constructor Summary |
Human(String name)
Constructor for objects of class Human |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Human
public Human(String name)
- Constructor for objects of class Human
- Parameters:
name,
- the Human's name
amputate
public void amputate(int howMany)
- amputate method
- Parameters:
howMany
- how many legs to amputate
move
public String move()
- move method
- Overrides:
move
in class Animal
- Returns:
- a description of the motion
toString
public String toString()
- toString method
- Overrides:
toString
in class Object
- Returns:
- a String representation of the Human
Generated by BlueJ