Class PointFactory


  • public class PointFactory
    extends java.lang.Object
    The PointFactory class : This is the factory to create and add new points, that represent the coordinates in the project It is uses the simple factory design pattern
    • Constructor Summary

      Constructors 
      Constructor Description
      PointFactory()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.awt.Point addPoint​(int x, int y)
      This method creates a new point instance
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • PointFactory

        public PointFactory()
    • Method Detail

      • addPoint

        public static java.awt.Point addPoint​(int x,
                                              int y)
        This method creates a new point instance
        Parameters:
        x - the x coordinate on the x-axis
        y - the y coordinate on the y-axis
        Returns:
        the Point instance