gistoolkit.server.mapclient
Class Extents

java.lang.Object
  extended bygistoolkit.server.mapclient.Extents

public class Extents
extends java.lang.Object

Represents a rectangular bounding box. Typically it is used for the minimum bounding rectangle for a particular geographic feature.


Field Summary
 double myBottomX
           
 double myBottomY
           
 double myTopX
           
 double myTopY
           
 
Constructor Summary
Extents()
          Create a new Extents with null values.
Extents(double inTopX, double inTopY, double inBottomX, double inBottomY)
          Create a new Extents with the given values.
 
Method Summary
 java.lang.Object clone()
          Create a copy of the bounds.
 boolean contains(Extents inExtents)
          Determines if the Extents sent in is within the current Extents.
 double getBottomX()
           
 double getBottomY()
           
 double getHeight()
          Returns the height of this extents
 double getTopX()
           
 double getTopY()
           
 double getWidth()
          Returns the width of this extents
 java.lang.String toString()
          The to string method for debugging.
 void translate(double inXDistance, double inYDistance)
          Translate the extents the given distance.
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

myTopX

public double myTopX

myTopY

public double myTopY

myBottomX

public double myBottomX

myBottomY

public double myBottomY
Constructor Detail

Extents

public Extents()
Create a new Extents with null values.


Extents

public Extents(double inTopX,
               double inTopY,
               double inBottomX,
               double inBottomY)
Create a new Extents with the given values. The bottomX is the maximum X, and the Top X is the minimum X.

Method Detail

getTopX

public double getTopX()

getTopY

public double getTopY()

getBottomX

public double getBottomX()

getBottomY

public double getBottomY()

clone

public java.lang.Object clone()
Create a copy of the bounds. Creation date: (4/13/2001 4:53:50 PM)

Returns:
features.Bounds

toString

public java.lang.String toString()
The to string method for debugging. Creation date: (4/13/2001 5:22:03 PM)

Returns:
java.lang.String

contains

public boolean contains(Extents inExtents)
Determines if the Extents sent in is within the current Extents. Compares with equality, such that if the Extents sent in is the same as the current Extents, then the result will be true.


getWidth

public double getWidth()
Returns the width of this extents


getHeight

public double getHeight()
Returns the height of this extents


translate

public void translate(double inXDistance,
                      double inYDistance)
Translate the extents the given distance.