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.
Answers were Sorted based on User's Feedback
Answer / 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 |
Answer / venkat
Marker Inferface doesnt consists any methods
it gives prior intemation to JVM to treat specially
Ex:Serialiazable
singleThread
| Is This Answer Correct ? | 0 Yes | 0 No |
Diff between C++ and java?
what is the life cycle of jsp?
What are internal and external variables?
What is difference between fileinputstream and filereader in java?
What is the difference between a static and a non-static inner class in java programming?
What is the difference between integer parseint and integer valueof?
What is the difference between Grid and Gridbaglayout?
Why arraylist is not synchronized in java example?
program to find 25 square = 625 here the 625 of last two digits is equal to 25, i don't know excatly what this type of number is called
Define the term string pool?
What are the different types of data structures in java?
What is the difference between instanceof and isinstance?