Code example for DataInput

Methods: readBoolean

0
    } 
 
    @Override 
    public void readData(DataInput in) throws IOException {
        address = new Address();
        address.readData(in);
        add = in.readBoolean();
    } 
 
    @Override 
    public void writeData(DataOutput out) throws IOException {
        address.writeData(out);
        out.writeBoolean(add);
    } 
 
    @Override 
    public String toString() {
        return "AddOrRemoveConnection add=" + add + ", " + address;
    } 
 
    public void process() {