Code example for DataInput

Methods: readDouble, readUTF

0
	private double change;
	private static final String DELIMITER = "\t";
	 
	@Override 
	public void readFields(DataInput in) throws IOException {
		symbol = in.readUTF();
		date = in.readUTF();
		change = in.readDouble();
	} 
 
	@Override 
	public void write(DataOutput out) throws IOException {
		out.writeUTF(symbol);
		out.writeUTF(date);
		out.writeDouble(change);
	} 
 
	public String getSymbol() {
		return symbol;
	}