/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package usda.weru.util.gis;

import java.io.DataInputStream;
import java.io.IOException;

/**
 *
 * @author wjr
 */
public class RecordHeader {

    int recordNumber = 0;
    int contentLength = 0;
    int recordType = 0;

    void read(DataInputStream in) throws IOException {
        recordNumber = in.readInt();
        contentLength = in.readInt() * 2;
        recordType = Swab.swab(in.readInt());
    }

	/**
	 *
	 * @return
	 */
	@Override
    public String toString() {
        return "record number " + recordNumber + " content length " + contentLength + " record type " + recordType;
    }
}