| Author |
Abstract class and Interface
|
saravana kumar
Ranch Hand
Joined: Jun 25, 2002
Posts: 72
|
|
can a abstract class exist without abstract method ? is it possible a interface class has empty body ?
|
 |
Ernest Friedman-Hill
author and iconoclast
Marshal
Joined: Jul 08, 2003
Posts: 24050
|
|
|
Yes, you can have an abstract class with no abstract methods. Yes, you can have empty interfaces -- like java.lang.Cloneable and java.io.Serializable.
|
[Jess in Action][AskingGoodQuestions]
|
 |
Phani Kumar
Greenhorn
Joined: Feb 15, 2002
Posts: 22
|
|
|
You can have interface without body and it has got a special name "Marker interface"
|
 |
 |
|
|
subject: Abstract class and Interface
|
|
|