public abstract class Dimension2D extends java.lang.Object implements java.lang.Cloneable
| Modifier | Constructor and Description |
|---|---|
protected |
Dimension2D()
The default constructor.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
clone()
Create a new dimension of the same run-time type with the same contents
as this one.
|
abstract double |
getHeight()
Get the height of this dimension.
|
abstract double |
getWidth()
Get the width of this dimension.
|
void |
setSize(Dimension2D d)
Set the size of this dimension to the requested value.
|
abstract void |
setSize(double w,
double h)
Set the size of this dimension to the requested values.
|
protected Dimension2D()
public abstract double getWidth()
public abstract double getHeight()
public abstract void setSize(double w, double h)
w - the new widthh - the new heightpublic void setSize(Dimension2D d)
d - the dimension containing the new valuesjava.lang.NullPointerException - if d is nullpublic java.lang.Object clone()
clone in class java.lang.Objectjava.lang.OutOfMemoryError - If there is not enough memory available.Cloneable