Create a class hierarchy

How do i create a Java class hierarchy for my program. What are common classes that programs use that would be included in the hierarchy? Help would really be appreciated.
[178 byte] By [student85a] at [2007-11-27 3:54:00]
# 1

class Thing {}

class Fruit extends Thing {}

class Banana extends Fruit {}

class Apple extends Fruit {}

class Animal extends Thing {}

class Dog extends Animal {}

class Monkey extends Animal {}

DrLaszloJamfa at 2007-7-12 8:58:05 > top of Java-index,Java Essentials,New To Java...
# 2

^^ that pretty much sums up how to do it

but inheritance is basically the guts of java, super duper important concept to understand. So i suggest sitting down with a good java book for a couple hours, and completely grasp the ideas of inheretance, polymorphism, encapsulation .. all that good stuff.

personally i like The Complete Reference books. i studied with them and they really do help alot

Lopatina at 2007-7-12 8:58:05 > top of Java-index,Java Essentials,New To Java...
# 3
Keep in mind that you don't necessarily need a hierarchy of classes (unless you count the fact that all classes extend Object). You need a collection of classes. The classes you create may or may not create hierarchy among themselves, but they don't have to.
paulcwa at 2007-7-12 8:58:05 > top of Java-index,Java Essentials,New To Java...