Of the three classes you've mentioned only two are legal (also watch the spelling on implements)
class A extends class B { }
class A implements class b{ }
In the cases above extends denotes that you are inheriting from a class. implements denotes that you are using an interface. Check out the java tutorial for more information on interfaces.
Also just to mix you up slightly more you can also make an interface extend another interface like this
Originally posted by David Milligan: When you say about an interface extending another, does the interface refer to a class.
No, an interface is an interface, not a class. A class can extend a class, and an interface can extend an interface, but a class does not extend an interface nor does an interface extend a class. A class implements an interface.
Also you should note that you do not include the class/interface word when you use them after extends/implements.
As already mentioned classes and interfaces can refer to very different things and it would be advisable to familiarise yourself with the concepts on the Java Tutorial. Have fun! Barry
Actually I am new in JAVA & whatever u discuused is very good & details but as per it is my primary stage so I will read that toutorial & if Any diffuculty will occuer i will contact u again. Thanks for replying me message.
------------
The main thing in Programming is that it can be do by verious ways
Yeast devil! Back to the oven that baked you! And take this tiny ad too:
Free, earth friendly heat - from the CodeRanch trailboss