• Post Reply Bookmark Topic Watch Topic
  • New Topic

Difference Between Abstract and Interface  RSS feed

 
Maheswaran Devaraj
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I want to know where we have to use abstract class and where we have to use the Interface.

Regards,
Maheswaran
 
Vijitha Kumara
Saloon Keeper
Posts: 3999
42
Chrome Fedora Hibernate
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you want to provide some/common implementations for certain behaviors you may use abstract classes whereas interfaces (being 100% abstract) you force the implemented class to implement the behavior. You may find lots of information by searching through the forums (java) here. And find this Sun tutorial which would be helpful.
 
Campbell Ritchie
Marshal
Posts: 55772
163
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"Maheswaran" please read the important administrative private message I just sent you.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!