What is Marker interface in java? and what is clone?
Answer Posted / kavya
Use of marker interface in java
Marker Interfaces are used to indicate something to compiler/JVM. If JVM see that a class is a object of Marker Interface then it will perform some special operation. Take an example with Serializable, Clonnable marker interface, if JVM see a Class is Serialized/Clonnable then It will do some special operation on it, similar way if JVM sees one Class is implemented custom marker interface which is created by ourself then the JVM do some special operation. How it’d do the special operation
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How to instantiate static nested classes in java?
Give some features of interface?
What is the difference between the paint() and repaint() methods?
What is time complexity algorithm?
How to sort array of 0 and 1 in java?
What are the basic control structures?
What is singleton class in ruby?
What are the uses of java?
What is constructor and virtual function? Can we call a virtual function in a constructor?
What is ph and buffers?
what is the messsage u r going to get from an objectoriented programing?
Write a java program to count the number of words present in a string?
What are "class access modifiers" in Java?
Can a static class have a constructor java?
What are loops in java?