Class DimensionImpl

java.lang.Object
org.refcodes.graphical.DimensionImpl
All Implemented Interfaces:
Dimension, HeightAccessor, WidthAccessor

public class DimensionImpl extends Object implements Dimension
The Class DimensionImpl.
Author:
steiner
  • Field Details

    • _width

      protected int _width
    • _height

      protected int _height
  • Constructor Details

    • DimensionImpl

      protected DimensionImpl()
      Instantiates a new dimension impl.
    • DimensionImpl

      public DimensionImpl(int aWidth, int aHeight)
      Instantiates a new dimension impl.
      Parameters:
      aWidth - the width
      aHeight - the height
  • Method Details

    • getWidth

      public int getWidth()
      Retrieves the width from the width property.
      Specified by:
      getWidth in interface WidthAccessor
      Returns:
      The width stored by the width property.
    • getHeight

      public int getHeight()
      Retrieves the height from the height property.
      Specified by:
      getHeight in interface HeightAccessor
      Returns:
      The height stored by the height property.
    • toString

      public String toString()
      Overrides:
      toString in class Object