/*
 * 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 Box extends java.awt.geom.Rectangle2D.Double {
    private static final long serialVersionUID = 1L;

    double minX;
    double minY;
    double maxX;
    double maxY;

	/**
	 *
	 */
	public Box() {
        super();
    }

	/**
	 *
	 * @param in
	 * @throws IOException
	 */
	public Box (DataInputStream in) throws IOException {
        this();
        read(in);
    }

    void read(DataInputStream in) throws IOException {
        minX = Swab.swab(in.readDouble());
        minY = Swab.swab(in.readDouble());
        maxX = Swab.swab(in.readDouble());
        maxY = Swab.swab(in.readDouble());
    }
}
