When should I use abstract classes and when should I use
interfaces?
Answers were Sorted based on User's Feedback
Answer / ved.b.tripathi
Interface : when you about to maintain the standard through
out the application then,blindly go with the interface.
Abstract : when you customize the behavior but still want to
maintain some standard then use abstract,because in abstract
you can have non abstract method that will be use by every
class that extend this abstract method and that class also
have to give the body of abstract methods(standard).
| Is This Answer Correct ? | 15 Yes | 2 No |
In Java, what types of classes perform inheritance?
What are different access specifiers in java?
How does hashset works in java?
What is classpath?
Can You Have Virtual Functions In Java?
Which collection is sorted in java?
Is there a sort function in java?
What is a text string?
How to overcome the exception object reference not set to an instance of object?
Does garbage collection occur in permanent generation space in jvm?
What is the driver class?
Which graphs are functions?