|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object magoffin.matt.ma2.support.Geometry
public class Geometry
Simple class to represent a width and height.
Nested Class Summary | |
---|---|
static class |
Geometry.Mode
Geometry mode. |
Constructor Summary | |
---|---|
Geometry()
Default constructor. |
|
Geometry(int width,
int height)
Construct a Geometry with width and height. |
|
Geometry(int width,
int height,
Geometry.Mode mode)
Construct a Geometry with width, height, and mode. |
Method Summary | |
---|---|
int |
getHeight()
Returns the height. |
Geometry.Mode |
getMode()
Returns the mode. |
int |
getWidth()
Returns the width. |
void |
reset()
Reset this object to its default state. |
void |
setHeight(int height)
Sets the height. |
void |
setMode(Geometry.Mode mode)
Sets the mode. |
void |
setWidth(int width)
Sets the width. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Geometry()
public Geometry(int width, int height)
width
- height
- public Geometry(int width, int height, Geometry.Mode mode)
width
- height
- mode
- Method Detail |
---|
public int getHeight()
public int getWidth()
public void setHeight(int height)
height
- The height to setpublic void setWidth(int width)
width
- The width to setpublic Geometry.Mode getMode()
The mode should be one of the defined constants Geometry.Mode.MAX
,
Geometry.Mode.MIN
, or Geometry.Mode.EXACT
.
public void setMode(Geometry.Mode mode)
The mode should be one of the defined constants Geometry.Mode.MAX
,
Geometry.Mode.MIN
, or Geometry.Mode.EXACT
.
mode
- the new modepublic void reset()
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |