Interface Rectangular

    • Method Summary

      All Methods Instance Methods Abstract Methods Default Methods 
      Modifier and Type Method Description
      default double[] getCoordinates()
      Gets the coordinates of the rectangular shape.
      double getHeight()
      Returns the height of the rectangular shape.
      double getWidth()
      Returns the width of the rectangular shape.
      double getX()
      Returns the x-coordinate of the rectangular shape.
      double getY()
      Returns the y coordinate of the rectangular shape.
      default void setCoordinates​(double[] coordinates)
      Sets the coordinates of the rectangular shape.
      default void setCoordinates​(double x, double y, double width, double height)
      Sets the coordinates of the rectangular shape.
      void setHeight​(double height)
      Sets the height of the rectangular shape.
      void setWidth​(double width)
      Sets width of the rectangular shape.
      void setX​(double x)
      Sets the x-coordinate of the rectangular shape.
      void setY​(double y)
      Sets the y-coordinate of the rectangular shape.
    • Method Detail

      • getX

        double getX()
        Returns the x-coordinate of the rectangular shape.
        Returns:
        See above.
      • setX

        void setX​(double x)
        Sets the x-coordinate of the rectangular shape.
        Parameters:
        x - See above.
      • getY

        double getY()
        Returns the y coordinate of the rectangular shape.
        Returns:
        See above.
      • setY

        void setY​(double y)
        Sets the y-coordinate of the rectangular shape.
        Parameters:
        y - See above.
      • getWidth

        double getWidth()
        Returns the width of the rectangular shape.
        Returns:
        See above.
      • setWidth

        void setWidth​(double width)
        Sets width of the rectangular shape.
        Parameters:
        width - See above.
      • getHeight

        double getHeight()
        Returns the height of the rectangular shape.
        Returns:
        See above.
      • setHeight

        void setHeight​(double height)
        Sets the height of the rectangular shape.
        Parameters:
        height - See above.
      • setCoordinates

        default void setCoordinates​(double x,
                                    double y,
                                    double width,
                                    double height)
        Sets the coordinates of the rectangular shape.
        Parameters:
        x - The x-coordinate of the top-left corner.
        y - The y-coordinate of the top-left corner.
        width - The width of the rectangular shape.
        height - The height of the rectangular shape.
      • getCoordinates

        default double[] getCoordinates()
        Gets the coordinates of the rectangular shape.
        Returns:
        Array of coordinates containing {X,Y,Width,Height}.
      • setCoordinates

        default void setCoordinates​(double[] coordinates)
        Sets the coordinates of the rectangular shape.
        Parameters:
        coordinates - Array of coordinates containing {X,Y,Width,Height}.