What are the performance implications of interfaces over abstract classes?
Answer / shakir
Interfaces are slower in performance as compared to abstract classes as extra indirections are required for interfaces. Another key factor for developers to take into consideration is that any class can extend only one abstract class while a class can implement many interfaces.
Use of interfaces also puts an extra burden on the developers as any time an interface is implemented in a class; developer is forced to implement each and every method of interface.
| Is This Answer Correct ? | 0 Yes | 0 No |
What are different type of access modifiers?
Functionality of JVM?
What is variable length arguments in java?
why Java does not support multiple inheritances?
Can we override private constructor in java?
What is the relationship difference the canvas class and the graphics class?
What is the benefit of singleton pattern?
What is the difference between jfc & wfc?
Why vector class is used?
What is java in simple terms?
How many threads can I run java?
How does sublist works in java?