java.lang.Objectedu.gwu.champAlg.Pointd
public class Pointd
Pointd class implements a class corresponding to 2-dimensional points in the plane specified by type double x and y coordinates.
| Field Summary | |
|---|---|
double |
x
Variables specifying a point instance. |
double |
y
|
| Constructor Summary | |
|---|---|
Pointd()
Default Pointd constructor: x=y=0. |
|
Pointd(double x,
double y)
Pointd constructor. |
|
| Method Summary | |
|---|---|
Pointd |
copy()
|
boolean |
equals(java.lang.Object obj)
Return true if the point instance equals the input point instance. |
boolean |
equals(Pointd p)
Return true if the point instance equals point p. |
java.lang.String |
toString()
Return string representation of Pointd instance. |
| Methods inherited from class java.lang.Object |
|---|
getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public double x
public double y
| Constructor Detail |
|---|
public Pointd(double x,
double y)
public Pointd()
| Method Detail |
|---|
public java.lang.String toString()
toString in class java.lang.Objectpublic boolean equals(Pointd p)
public boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic Pointd copy()