treemap
Class Rect
java.lang.Object
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)
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
x
public double x
y
public double y
w
public double w
h
public double h
Rect
public Rect()
Rect
public Rect(Rect r)
Rect
public Rect(double x,
double y,
double w,
double h)
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