As Java does not support multiple inheritance, when you need to have a class (or abstract class) that contains various features, you have to use interfaces.
Hi, Nicolas is right,When u have to use an abstract class the methods in abstract class have to be marked abstract,and when this class is subclassed, subclass need to provide the relevant implementation for each abstract method,while interfaces methods in Interfaces are abstract by virtue of their declaration,and should not be declared abstract.Also an Interface is abstract by definition and therefore cannot be instayiated.it should not be declared abstract.
"Do not be afraid of going slow, be afraid of standing still"
Originally posted by Nicholas Cheung: As Java does not support multiple inheritance, when you need to have a class (or abstract class) that contains various features, you have to use interfaces.
Nick
Wow nick what a long list of degrees ?..a studious guy i shud say
Thnx
When all four tires fall off your canoe, how many tiny ads does it take to build a doghouse?
a bit of art, as a gift, the permaculture playing cards