GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Tech FAQs  >  Programming  >  Java
Go To First  |  Previous Question  |  Next Question 
 Java  |  Question 704 of 937    Print  
What is the difference between abstract class and interface?

  
Total Answers and Comments: 4 Last Update: November 08, 2006     Asked by: subbu 
  
 Sponsored Links

 
 Best Rated Answer

No best answer available. Please pick the good answer available or submit your answer.
November 01, 2006 08:01:20   
manish        

RE: What is the difference between abstract class and ...
1 . abstract class have a concreate Method while interface have no method implementetion2. abstract class comes in to inherit chain while interface dont
 
Is this answer useful? Yes | No
November 02, 2006 08:50:19   
bhabani        

RE: What is the difference between abstract class and ...

Abstract class may have concrete methods which need not require to be overridden but In Interface all methods need to be overridden .

Abstrct classes are Extended but interfaces are implemented .

in an interface all the methods are by default Abstract.


 
Is this answer useful? Yes | No
November 08, 2006 02:42:12   
niranajn        

RE: What is the difference between abstract class and ...

In Abstract class we can have non-abstract methods.Atleast one method should be abstract others may be abstract or concrete.

Where as i Interface we dont have non-abstract methods.

In abstract classes we use the keyword abstract for the methods where as in interfaces we dont use any such keyword.

Using interfaces the concept of multiple inheritance is acheived but this can not be done with abstract classes.


 
Is this answer useful? Yes | No
November 08, 2006 07:12:37   
Radhakrishna        

RE: What is the difference between abstract class and ...

hi

Diff b/w abstract class and interface are..

Abstract class can have concrete methods also..eventhough if the class doesn't contain any abstract method we can declare that class as an Abstract class.

In case of Interface by default methods are abstract and public only. In the interface also there is a possibility of defining concrete methods using the InnerClasses concept..


 
Is this answer useful? Yes | No


 
Go To Top


 Sponsored Links

 
About Us -  Privacy Policy -  Terms and Conditions -  Contact -  Ask Question -  Propose Category -  Site Updates 

Copyright © 2005 - 2010 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape