Java.io.ObjectOutputStream.writeObject() Method


Advertisements


Description

The java.io.ObjectOutputStream.writeObjectOverride(Object obj) method is used by subclasses to override the default writeObject method. This method is called by trusted subclasses of ObjectInputStream that constructed ObjectInputStream using the protected no-arg constructor. The subclass is expected to provide an override method with the modifier "final".

Declaration

Following is the declaration for java.io.ObjectOutputStream.writeObjectOverride() method.

protected void writeObjectOverride(Object obj)

Parameters

obj − object to be written to the underlying stream.

Return Value

This method does not return a value.

Exception

IOException − If there are I/O errors while writing to the underlying stream.


java_io_objectoutputstream.htm

Advertisements