This week's book giveaway is in the Agile and other Processes forum. We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line! See this thread for details.
When will we use abstract interfaces and how ? pls. help me out & Why interfaces cannot be instantiated ? are abstract classes instantiated ? Do tell with good examples
Smiling on Java
Tim West
Ranch Hand
Joined: Mar 15, 2004
Posts: 539
posted
0
Interesting, a very similar topic was discussed in this forum not-so-long ago, here. I'd look at Bruce Eckel's Thinking In Java for excellent discussion and examples. If I were you, I'd also consider reading this. --Tim [ April 22, 2004: Message edited by: Tim West ]
Ali Gohar
Ranch Hand
Joined: Mar 18, 2004
Posts: 572
posted
0
First thing that Interface are always abstrat and can't be instantiated because they only declare methods in it not define them thats why they can't get instantiated same is for abstract class that it might 1 or more methods which it doesn't implement or define thats why we can't make object of abstract classes too. Both are very useful at different places. I think you don't have the idea of polymorphism and inheritance thats why you asked that question. Do read these concepts and it will be clear.