Package com.oorian

Class Size

java.lang.Object
com.oorian.Size

public class Size extends Object
Represents a two-dimensional size with width and height.

Size is used throughout the Oorian framework to represent screen dimensions, window dimensions, and element sizes. It stores width and height as integers representing pixels.

Usage:


 Size screenSize = clientProfile.getScreenSize();
 int width = screenSize.getWidth();
 int height = screenSize.getHeight();
 
Since:
2021
Version:
1.0
Author:
Marvin P. Warble Jr.
See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructs a new Size with default dimensions (0, 0).
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Returns the height dimension.
    int
    Returns the width dimension.
    void
    setSize(int width, int height)
    Sets the width and height dimensions.
    void
    setSize(Size size)
    Copies the dimensions from another Size object.

    Methods inherited from class java.lang.Object

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

    • Size

      public Size()
      Constructs a new Size with default dimensions (0, 0).
  • Method Details

    • setSize

      public void setSize(Size size)
      Copies the dimensions from another Size object.
      Parameters:
      size - the Size to copy from
    • setSize

      public void setSize(int width, int height)
      Sets the width and height dimensions.
      Parameters:
      width - the width in pixels
      height - the height in pixels
    • getWidth

      public int getWidth()
      Returns the width dimension.
      Returns:
      the width in pixels
    • getHeight

      public int getHeight()
      Returns the height dimension.
      Returns:
      the height in pixels