Code example for DataOutput

Methods: writeUTF

0
        return message;
    } 
 
	@Override 
	public void toStream(DataOutput out) throws IOException {
        super.toStream(out);
		out.writeUTF(message);
	} 
 
	@Override 
	public void fromStream(DataInput in) throws IOException {
        super.fromStream(in);
        message = in.readUTF();
	} 
}