Code example for ObjectInput

Methods: readBooleanreadUTF

0
        } 
    } 
 
    public void readExternal(ObjectInput in) throws IOException,
                                            ClassNotFoundException { 
        if ( in.readBoolean() ) {
            msg = in.readUTF();
        } 
 
    } 
 
    public String getMessage() {
        return msg;
    } 
} 
Stop searching for code, let great code find you!  Add Codota to your java IDE