Class Point

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable

    public class Point
    extends Point2D
    implements java.io.Serializable
    See Also:
    Serialized Form
    • Field Detail

      • x

        public double x
      • y

        public double y
    • Constructor Detail

      • Point

        public Point()
      • Point

        public Point​(int x,
                     int y)
      • Point

        public Point​(double x,
                     double y)
      • Point

        public Point​(Point p)
    • Method Detail

      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class Point2D
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • getX

        public double getX()
        Specified by:
        getX in class Point2D
      • getY

        public double getY()
        Specified by:
        getY in class Point2D
      • getLocation

        public Point getLocation()
      • setLocation

        public void setLocation​(Point p)
      • setLocation

        public void setLocation​(int x,
                                int y)
      • setLocation

        public void setLocation​(double x,
                                double y)
        Specified by:
        setLocation in class Point2D
      • move

        public void move​(int x,
                         int y)
      • move

        public void move​(double x,
                         double y)
      • translate

        public void translate​(int dx,
                              int dy)
      • translate

        public void translate​(double dx,
                              double dy)