|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.moioli.chart.IntRectangle
public class IntRectangle
Represents a rectangle on a cartesian plane with integer coordinate.
Field Summary | |
---|---|
int |
height
The rectangle's height. |
int |
width
The rectangle's width. |
int |
x
x coordinate of the rectangle's top-left corner. |
int |
y
y coordinate of the rectangle's top-left corner. |
Constructor Summary | |
---|---|
IntRectangle()
Constructs a rectangle with vertexes in (0,0), (0,1), (1,0), (1,1). |
|
IntRectangle(int x,
int y,
int width,
int height)
Standard constructor. |
|
IntRectangle(IntRectangle r)
Copy constructor. |
Method Summary | |
---|---|
int |
getHeight()
Returns the rectangle's height. |
int |
getWidth()
Returns the rectangle's width. |
int |
getX()
Returns the x coordinate of the rectangle's top-left corner. |
int |
getY()
Returns the y coordinate of the rectangle's top-left corner. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public int x
public int y
public int width
public int height
Constructor Detail |
---|
public IntRectangle()
public IntRectangle(IntRectangle r)
r
- the rectangle to be copiedpublic IntRectangle(int x, int y, int width, int height)
x
- coordinate of the rectangle's top-left cornery
- coordinate of the rectangle's top-left cornerwidth
- the rectangle's widthheight
- the rectangle's heightMethod Detail |
---|
public int getX()
public int getY()
public int getWidth()
public int getHeight()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |