| 
 | JavaTM Platform Standard Ed. 6 | |||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
java.lang.Objectjava.awt.geom.Point2D
public abstract class Point2D
Point2D クラスは、(x,y) 座標空間の位置を表す点を定義します。
 
このクラスは、2D 座標を格納するすべてのオブジェクトの抽象スーパークラスにすぎません。座標の実際の記憶域表現はサブクラスに委ねられます。
| 入れ子のクラスの概要 | |
|---|---|
| static class | Point2D.DoubleDoubleクラスは、double精度で指定された点を定義します。 | 
| static class | Point2D.FloatFloatクラスは、float 精度で指定された点を定義します。 | 
| コンストラクタの概要 | |
|---|---|
| protected  | Point2D()これは、インスタンスを直接には生成できない abstract クラスです。 | 
| メソッドの概要 | |
|---|---|
|  Object | clone()このオブジェクトと同じクラスで、同じ内容の新しいオブジェクトを作成します。 | 
|  double | distance(double px,
         double py)この Point2Dから指定された点までの距離を返します。 | 
| static double | distance(double x1,
         double y1,
         double x2,
         double y2)2 つの点の間の距離を返します。 | 
|  double | distance(Point2D pt)この Point2Dから指定されたPoint2Dまでの距離を返します。 | 
|  double | distanceSq(double px,
           double py)この Point2Dから指定された点までの距離の 2 乗を返します。 | 
| static double | distanceSq(double x1,
           double y1,
           double x2,
           double y2)2 つの点の間の距離の 2 乗を返します。 | 
|  double | distanceSq(Point2D pt)この Point2Dから指定されたPoint2Dまでの距離の 2 乗を返します。 | 
|  boolean | equals(Object obj)2 つの点が等しいかどうかを判定します。 | 
| abstract  double | getX()この Point2Dの X 座標をdouble精度で返します。 | 
| abstract  double | getY()この Point2Dの Y 座標をdouble精度で返します。 | 
|  int | hashCode()この Point2Dのハッシュコードを返します。 | 
| abstract  void | setLocation(double x,
            double y)この Point2Dの位置を、指定されたdouble型の座標に設定します。 | 
|  void | setLocation(Point2D p)この Point2Dの位置を、指定されたPoint2Dオブジェクトと同じ座標に設定します。 | 
| クラス java.lang.Object から継承されたメソッド | 
|---|
| finalize, getClass, notify, notifyAll, toString, wait, wait, wait | 
| コンストラクタの詳細 | 
|---|
protected Point2D()
Point2D.Float, 
Point2D.Double, 
Point| メソッドの詳細 | 
|---|
public abstract double getX()
Point2D の X 座標を double 精度で返します。
Point2D の X 座標public abstract double getY()
Point2D の Y 座標を double 精度で返します。
Point2D の Y 座標
public abstract void setLocation(double x,
                                 double y)
Point2D の位置を、指定された double 型の座標に設定します。
x - この Point2D の新しい X 座標y - この Point2D の新しい Y 座標public void setLocation(Point2D p)
Point2D の位置を、指定された Point2D オブジェクトと同じ座標に設定します。
p - この Point2D を設定する、指定された Point2D
public static double distanceSq(double x1,
                                double y1,
                                double x2,
                                double y2)
x1 - 最初に指定された点の X 座標y1 - 最初に指定された点の Y 座標x2 - 2 番目に指定された点の X 座標y2 - 2 番目に指定された点の Y 座標
public static double distance(double x1,
                              double y1,
                              double x2,
                              double y2)
x1 - 最初に指定された点の X 座標y1 - 最初に指定された点の Y 座標x2 - 2 番目に指定された点の X 座標y2 - 2 番目に指定された点の Y 座標
public double distanceSq(double px,
                         double py)
Point2D から指定された点までの距離の 2 乗を返します。
px - この Point2D に対して測定される、指定された点の X 座標py - この Point2D に対して測定される、指定された点の Y 座標
Point2D と指定された点の間の距離の 2 乗public double distanceSq(Point2D pt)
Point2D から指定された Point2D までの距離の 2 乗を返します。
pt - この Point2D に対して測定される、指定された点
Point2D から指定された Point2D までの距離の 2 乗
public double distance(double px,
                       double py)
Point2D から指定された点までの距離を返します。
px - この Point2D に対して測定される、指定された点の X 座標py - この Point2D に対して測定される、指定された点の Y 座標
Point2D と指定された点の間の距離public double distance(Point2D pt)
Point2D から指定された Point2D までの距離を返します。
pt - この Point2D に対して測定される、指定された点
Point2D と指定された Point2D の間の距離public Object clone()
Object 内の cloneOutOfMemoryError - 十分なメモリがない場合Cloneablepublic int hashCode()
Point2D のハッシュコードを返します。
Object 内の hashCodePoint2D に使うハッシュコードObject.equals(java.lang.Object), 
Hashtablepublic boolean equals(Object obj)
Point2D の 2 つのインスタンスは、x および y メンバフィールド (座標空間でそれらの位置を表す) の値が同じ場合に等しくなります。
Object 内の equalsobj - この Point2D と比較されるオブジェクト
Point2D のインスタンスであり、同じ値を持つ場合は true、そうでない場合は falseObject.hashCode(), 
Hashtable| 
 | JavaTM Platform Standard Ed. 6 | |||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
Copyright 2009 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Documentation Redistribution Policy も参照してください。