1) Can we create our marker interface in java without extends Serializable Interface
2) Otherwise how can we instruct to jvm this is my marker interface if we create.
3) How JVM will know the default marker interface or is there any specification java using to indicate to jvm
You seem to get the wrong idea about marker interface. java.io.Serializable is an example of a marker interface in the sense that its purpose is only to tell that the class is serializable. It has no method at all.
A better way to achieve the same thing is to use annotation.
Hope it helps.
SCJP 5.0, SCWCD 1.4, SCBCD 1.3, SCDJWS 1.4
Joined: Mar 22, 2005
The JVM doesn't need to know about any marker interface you create (and it won't). And there is no "default" marker interface - all of them are created equal.