Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Difference Between Abstract and Interface

 
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
Bartender
Pie
Posts: 3918
10
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
Sheriff
Pie
Posts: 50225
79
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"Maheswaran" please read the important administrative private message I just sent you.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic