Hi All , I am curious know something about the Null interface . What are they ? Can Cloneable , Serializable be called as Null interfaces ? Please let me know. Thanks.
Joined: Aug 26, 2001
... A null interface is an interface with no method declaration. I don't really like this term since "null" has a special meaning in Java. I would prefer calling such an interface an "empty interface" or better a "tag interface" but not a "null interface". Maybe someone else has an idea as to why such interfaces have been called "null interfaces". I don't know who invented that but "null interface" does not exist in the official Java terminology. [ December 10, 2002: Message edited by: Valentin Crettaz ]
To support with an example from the J2SE API Documentation, you'll see that Serializable is a marker interface, in its comment its written that All subtypes of a serializable class are themselves serializable.
BTW shewta, ArrayList is a concrete final class, its not an interface rather an implementation of RandomAccess marker interface.
Ashik Uzzaman Senior Member of Technical Staff, Salesforce.com, San Francisco, CA, USA.