Hey buddy.. can you please tell me about the use of marker
interface? And is there any link between marker interface
and factory methods?
Thanks in advance.
Answer Posted / namita
Marker Interface or sometimes called as Tagging interface
are empty interface which means it does not have any
methods. The use of the these interface is below
Like clonneable interface which is also a marker interface
when ur code implements clonneable interface the JVM will
come to know that you want to clone the object by calling
clone method(). Similalry serializable interface needs to
be implemented when you want to serialize the objects.
Their implementation is just to make aware the JVM.
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What is object cloning in Java?
What are loops in java?
What is a type parameter in java?
Which data type is a class in java?
Hi i am creating desktop application in that i want calling to mobile number. i have java telephone api (JTAPI) but i dont understand how it configure & use plese help me
What are synchronized blocks in java?
Can list have duplicates in java?
What are the wrapped, classes?
Why is java logo a cup of coffee?
What class allows you to read objects directly from a stream?
What happens if an exception is not handled in a program?
Is oracle java 11 free?
Is string pool garbage collected?
Which arithmetic operations can result in the throwing of an arithmeticexception?
What is * argv?