Interface java.io.Externalizable
All Packages Class Hierarchy This Package Previous Next Index
Interface java.io.Externalizable
- public interface Externalizable
- extends Object
- extends Serializable
-
readExternal(ObjectInput)
- The object implements the readExternal method to restore its
contents by calling the methods of DataInput for primitive
types and readObject for objects, strings and arrays.
-
writeExternal(ObjectOutput)
- The object implements the writeExternal method to save its contents
by calling the methods of DataOutput for its primitive values or
calling the writeObject method of ObjectOutput for objects, strings
and arrays.
writeExternal
public abstract void writeExternal(ObjectOutput out) throws IOException
- The object implements the writeExternal method to save its contents
by calling the methods of DataOutput for its primitive values or
calling the writeObject method of ObjectOutput for objects, strings
and arrays.
readExternal
public abstract void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
- The object implements the readExternal method to restore its
contents by calling the methods of DataInput for primitive
types and readObject for objects, strings and arrays. The
readExternal method must read the values in the same sequence
and with the same types as were written by writeExternal.
- Throws: ClassNotFoundException
- If the class for an object being restored cannot be found.
All Packages Class Hierarchy This Package Previous Next Index