@Test public void setLocationByDoubleParamTest() { Point first = new Point(1.23, 1.1); Point second = new Point(3.59, 0.87); Assert.assertNotEquals(first, second); first.setLocation(second.x, second.y); Assert.assertEquals(first, second); }
public void setLocation(Point p) { setLocation(p.x, p.y); }
Point implements Serializable, Cloneable { public void setLocation(Point p) { setLocation(p.x, p.y); } }
Point implements Serializable, Cloneable { public void setLocation(Point p) { setLocation(p.x, p.y); } Point();  Point(int x, int y);  Point(double x, double y);  Point(Point p); }
Point implements Serializable, Cloneable { public void setLocation(Point p) { setLocation(p.x, p.y); } Point();  Point(int x, int y);  Point(double x, double y);  Point(Point p); @Override boolean equals(Object obj); @Override String toString(); double getX(); double getY(); Point getLocation(); void setLocation(Point p); void setLocation(int x, int y); void setLocation(double x, double y); void move(double x, double y); void translate(double dx, double dy); @Override int hashCode(); static double distanceSq(double x1, double y1, double x2, double y2); double distanceSq(double px, double py); double distanceSq(Point p); static double distance(double x1, double y1, double x2, double y2); double distance(double px, double py); double distance(Point p); @SuppressWarnings("CloneDoesntCallSuperClone") @Override Object clone(); }
Point implements Serializable, Cloneable { public void setLocation(Point p) { setLocation(p.x, p.y); } Point();  Point(int x, int y);  Point(double x, double y);  Point(Point p); @Override boolean equals(Object obj); @Override String toString(); double getX(); double getY(); Point getLocation(); void setLocation(Point p); void setLocation(int x, int y); void setLocation(double x, double y); void move(double x, double y); void translate(double dx, double dy); @Override int hashCode(); static double distanceSq(double x1, double y1, double x2, double y2); double distanceSq(double px, double py); double distanceSq(Point p); static double distance(double x1, double y1, double x2, double y2); double distance(double px, double py); double distance(Point p); @SuppressWarnings("CloneDoesntCallSuperClone") @Override Object clone(); public double x; public double y; }