difference between Abstract and Interface?
Answer Posted / ravi raj
Abstract Class:
---------------
1.abstract class contain the abstract and non-abstract methods
2.abstract class contain static and non-static variables
3.through abstract class we can get 0-50% abstraction in java
4. if any class declared as a abstract i.e abstract class
5. we wont create instance for this class.
6. we cont make final for this class.
Interface :
-----------
1. Interface contains only abstracted methods.
2. it allows only static and final variables.
3. interface is by default abstracted and public.
4. through interface we get 100% abstraction.
5. we can solve the multiple threading in interface.
Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
Explain what is orm?
How a component can be placed on Windows?
Do I need to import javlang package any time? Why ?
What is the difference between the ‘font’ and ‘fontmetrics’ class?
Is a class a subclass of itself?
What is the argument type of a programs main() method?
How to implement RMI in Java?
What is the difference between the session.update() method and the session.lock() method?
Write a singleton program?
What is metaspace?
What are the benefits of detached objects?
What is the difference between RMI registry and OS Agent?
Describe responsibilities of Activator?
Can you give me a simple example of using the requiredif validator rule?
What is the purpose of the notifyall() method?