public static class Point2D.Double extends Point2D implements Serializable
Double类定义一个点
double指定精度。
Point2D.Double, Point2D.Float| Modifier and Type | Field and Description |
|---|---|
double |
x
这
Point2D X坐标。
|
double |
y
这
Point2D Y坐标。
|
| Constructor and Description |
|---|
Double()
构造和初始化一个
Point2D坐标(0, 0)。
|
Double(double x, double y)
构造和初始化一个
Point2D与指定的坐标。
|
| Modifier and Type | Method and Description |
|---|---|
double |
getX()
返回x坐标本
Point2D在
double精度。
|
double |
getY()
返回
double精度这
Point2D Y坐标。
|
void |
setLocation(double x, double y)
设置此
Point2D定位到指定的
double坐标。
|
String |
toString()
返回一个
String表示此
Point2D价值。
|
clone, distance, distance, distance, distanceSq, distanceSq, distanceSq, equals, hashCode, setLocationpublic double x
Point2D X坐标。
public double y
Point2D Y坐标。
public Double()
Point2D坐标(0, 0)。
public Double(double x,
double y)
Point2D。
x -新建
Point2D X坐标
y -新建
Point2D Y坐标
public double getX()
Point2D在
double精度。
public double getY()
double精度这
Point2D Y坐标。
public void setLocation(double x,
double y)
Point2D定位到指定的
double坐标。
setLocation 方法重写,继承类
Point2D
x -新的X坐标本
Point2D
y -这
Point2D新的Y坐标
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.