Code example for ObjectOutput

Methods: writeByte, writeObject

0
    } 
 
 
    @Override 
    public void writeExternal( ObjectOutput out ) throws IOException {
        super.writeExternal( out );
 
        // VERSION 
        out.writeByte( 0 );
 
        // HASHING STRATEGY 
        if ( _hashingStrategy == this ) out.writeObject( null );
        else out.writeObject( _hashingStrategy );
    } 
 
    @Override 
    public void readExternal( ObjectInput in )
        throws IOException, ClassNotFoundException { 
 
        super.readExternal( in );