Code example for ObjectInput

Methods: readBooleanreadIntreadreadObject

0
        this.uuid = uuid;
        this.message = message;
    } 
 
    public void readExternal(ObjectInput in) throws IOException,ClassNotFoundException {
        reply = in.readBoolean();
        int length = in.readInt();
        uuid = new byte[length];
        in.read(uuid, 0, length);
        length = in.readInt();
        rpcId = new byte[length];
        in.read(rpcId, 0, length);
        message = (Serializable)in.readObject();
    } 
 
    public void writeExternal(ObjectOutput out) throws IOException {
        out.writeBoolean(reply);
        out.writeInt(uuid.length);
        out.write(uuid, 0, uuid.length);
        out.writeInt(rpcId.length);
Connect your IDE to all the code out there  Get Codota for Java