| Modifier | Constructor and Description |
|---|---|
protected |
Dimension2D()
这是一个无法直接实例化的抽象类。
|
| Modifier and Type | Method and Description |
|---|---|
Object |
clone()
创建与此对象相同类的新对象。
|
abstract double |
getHeight()
以双精度返回此
Dimension的高度。
|
abstract double |
getWidth()
以双精度返回此
Dimension的宽度。
|
void |
setSize(Dimension2D d)
设置此
Dimension2D对象的大小以匹配指定的大小。
|
abstract void |
setSize(double width, double height)
将此
Dimension对象的大小设置为指定的宽度和高度。
|
protected Dimension2D()
Dimension
public abstract double getWidth()
Dimension的宽度。
Dimension 。
public abstract double getHeight()
Dimension的高度。
Dimension的高度。
public abstract void setSize(double width,
double height)
width -
Dimension对象的新宽度
height -
Dimension对象的新高度
public void setSize(Dimension2D d)
Dimension2D对象的大小以匹配指定的大小。
包括这种方法的完整性,并行getSize方法的Component 。
d -
Dimension2D对象的新大小
public Object clone()
clone在类别
Object
OutOfMemoryError - 如果没有足够的内存
Cloneable
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.