javax.media.nativewindow.util
Class Dimension
java.lang.Object
javax.media.nativewindow.util.Dimension
- All Implemented Interfaces:
- WriteCloneable, Cloneable, DimensionImmutable
public class Dimension
- extends Object
- implements Cloneable, DimensionImmutable
Dimension
public Dimension()
Dimension
public Dimension(int width,
int height)
cloneMutable
public Object cloneMutable()
- Specified by:
cloneMutable
in interface WriteCloneable
clone
public Object clone()
- Overrides:
clone
in class Object
getWidth
public int getWidth()
- Specified by:
getWidth
in interface DimensionImmutable
getHeight
public int getHeight()
- Specified by:
getHeight
in interface DimensionImmutable
setWidth
public void setWidth(int width)
setHeight
public void setHeight(int height)
scale
public Dimension scale(int s)
add
public Dimension add(Dimension pd)
toString
public String toString()
- Overrides:
toString
in class Object
equals
public boolean equals(Object obj)
- Description copied from interface:
DimensionImmutable
- Checks whether two dimensions objects are equal. Two instances
of
DimensionReadOnly
are equal if two components
height
and width
are equal.
- Specified by:
equals
in interface DimensionImmutable
- Overrides:
equals
in class Object
- Returns:
true
if the two dimensions are equal;
otherwise false
.
hashCode
public int hashCode()
- Specified by:
hashCode
in interface DimensionImmutable
- Overrides:
hashCode
in class Object
Copyright 2010 JogAmp Community.