java.io.OptionalDataException (JDK 1.1)
This exception is thrown by the readObject() method of an ObjectInputStream when it encounters primitive type data where it expects object data. Despite the exception name, this data is not "optional," and object deserialization is aborted.
public classOptionalDataExceptionextends ObjectStreamException { //No Constructor//Public Instance Variablespublic booleaneof; public intlength; }
Hierarchy:
Object->Throwable(Serializable)->Exception->IOException->ObjectStreamException->OptionalDataException
Thrown By:
ObjectInputStream.readObject()