treemap
Class Rect

java.lang.Object
  extended by treemap.Rect

public class Rect
extends java.lang.Object

A JDK 1.0 - compatible rectangle class that accepts double-valued parameters.


Field Summary
 double h
           
 double w
           
 double x
           
 double y
           
 
Constructor Summary
Rect()
           
Rect(double x, double y, double w, double h)
           
Rect(Rect r)
           
 
Method Summary
 double aspectRatio()
           
 Rect copy()
           
 double distance(Rect r)
           
 void setRect(double x, double y, double w, double h)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

x

public double x

y

public double y

w

public double w

h

public double h
Constructor Detail

Rect

public Rect()

Rect

public Rect(Rect r)

Rect

public Rect(double x,
            double y,
            double w,
            double h)
Method Detail

setRect

public void setRect(double x,
                    double y,
                    double w,
                    double h)

aspectRatio

public double aspectRatio()

distance

public double distance(Rect r)

copy

public Rect copy()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object