Save This Page
Home » openjdk-7 » java » awt » geom » [javadoc | source]
java.awt.geom
abstract public class: Dimension2D [javadoc | source]
java.lang.Object
   java.awt.geom.Dimension2D

All Implemented Interfaces:
    Cloneable

Direct Known Subclasses:
    Dimension, DimensionUIResource

The Dimension2D class is to encapsulate a width and a height dimension.

This class is only the abstract superclass for all objects that store a 2D dimension. The actual storage representation of the sizes is left to the subclass.

Constructor:
 protected Dimension2D() 
Method from java.awt.geom.Dimension2D Summary:
clone,   getHeight,   getWidth,   setSize,   setSize
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from java.awt.geom.Dimension2D Detail:
 public Object clone() 
    Creates a new object of the same class as this object.
 abstract public double getHeight()
    Returns the height of this Dimension in double precision.
 abstract public double getWidth()
    Returns the width of this Dimension in double precision.
 public  void setSize(Dimension2D d) 
    Sets the size of this Dimension2D object to match the specified size. This method is included for completeness, to parallel the getSize method of Component.
 abstract public  void setSize(double width,
    double height)
    Sets the size of this Dimension object to the specified width and height. This method is included for completeness, to parallel the getSize method of java.awt.Component .