Documentation of 'sgtplot.util.Dimension2D' Java class
Dimension2D
sgtplot.util

Class Dimension2D



  • public class Dimension2D
    extends java.lang.Object
    A class to encapsulate a double width and a height.
    Since:
    sgtplot 1.0
    • Field Summary

      Fields 
      Modifier and Type Field and Description
      double height 
      double width 
    • Constructor Summary

      Constructors 
      Constructor and Description
      Dimension2D() 
      Dimension2D(double width, double height) 
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      boolean equals(Dimension2D d)
      Test for equality.
      double getHeight()
      Returns the height.
      double getWidth()
      Returns the width.
      void setSize(Dimension2D d)
      Set the size to match the specified size.
      void setSize(double width, double height)
      Set the size to the specified width and height.
      java.lang.String toString() 
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • height

        public double height
      • width

        public double width
    • Constructor Detail

      • Dimension2D

        public Dimension2D()
      • Dimension2D

        public Dimension2D(double width,
                           double height)
    • Method Detail

      • getWidth

        public double getWidth()
        Returns the width.
        Returns:
        the width
      • getHeight

        public double getHeight()
        Returns the height.
        Returns:
        the height
      • setSize

        public void setSize(double width,
                            double height)
        Set the size to the specified width and height. This method is included for completeness, to parallel the getSize method of Component.
        Parameters:
        width - the new width
        height - the new height
      • setSize

        public void setSize(Dimension2D d)
        Set the size to match the specified size. This method is included for completeness, to parallel the getSize method of Component.
        Parameters:
        d - the new size
      • toString

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

        public boolean equals(Dimension2D d)
        Test for equality. Both width and height must be equal to be true.

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.