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
对象的大小。该方法包括完整性、平行
Component
的
getSize
方法。
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.