public class IntRectangle
extends java.lang.Object
| Constructor and Description |
|---|
IntRectangle(double x,
double y,
int width,
int height)
Initialize a new instance of the IntRectangle class.
|
IntRectangle(DoublePoint p,
int width,
int height)
Initialize a new instance of the IntRectangle class.
|
IntRectangle(float x,
float y,
int width,
int height)
Initialize a new instance of the IntRectangle class.
|
IntRectangle(FloatPoint p,
int width,
int height)
Initialize a new instance of the IntRectangle class.
|
IntRectangle(int x,
int y,
int width,
int height)
Initialize a new instance of the IntRectangle class.
|
IntRectangle(IntPoint p,
int width,
int height)
Initialize a new instance of the IntRectangle class.
|
IntRectangle(IntRectangle rectangle)
Initialize a new instance of the IntRectangle class.
|
| Modifier and Type | Method and Description |
|---|---|
IntPoint[] |
getEdgePoints()
Get edge points of rectangle.
|
int |
getHeight()
Get height of rectangle.
|
int |
getWidth()
Get Width of rectangle.
|
int |
getX()
Get X axis coordinate.
|
int |
getY()
Get Y axis coordinate.
|
boolean |
isInside(int x,
int y)
Verify if the point is inside of rectangle.
|
boolean |
isInside(IntPoint p)
Verify if the point is inside of rectangle.
|
boolean |
isOverlaped(int x,
int y,
int width,
int height)
Verify if the rectangle is overlaped.
|
boolean |
isOverlaped(IntRectangle rect)
Verify if the rectangle is overlaped.
|
void |
setHeight(int height)
Set height of rectangle.
|
void |
setWidth(int width)
Set Width of rectangle.
|
void |
setX(int x)
Set X axis coordinate.
|
void |
setY(int y)
Set Y axis coordinate.
|
public IntRectangle(int x,
int y,
int width,
int height)
x - X axis coordinate.y - Y axis coordinate.width - Width.height - Height.public IntRectangle(float x,
float y,
int width,
int height)
x - X axis coordinate.y - Y axis coordinate.width - Width.height - Height.public IntRectangle(double x,
double y,
int width,
int height)
x - X axis coordinate.y - Y axis coordinate.width - Width.height - Height.public IntRectangle(IntPoint p, int width, int height)
p - Point contains X and Y coordinate.width - Width.height - Height.public IntRectangle(FloatPoint p, int width, int height)
p - Point contains X and Y coordinate.width - Width.height - Height.public IntRectangle(DoublePoint p, int width, int height)
p - Point contains X and Y coordinate.width - Width.height - Height.public IntRectangle(IntRectangle rectangle)
rectangle - Ractangle.public int getX()
public void setX(int x)
x - X axis coordinate.public int getY()
public void setY(int y)
y - Y axis coordinate.public int getHeight()
public void setHeight(int height)
height - Height.public int getWidth()
public void setWidth(int width)
width - Width.public boolean isInside(IntPoint p)
p - IntPoint contains X and Y coordinate.public boolean isInside(int x,
int y)
x - X axis coordinate.y - Y axis coordinate.public boolean isOverlaped(IntRectangle rect)
rect - Rectangle.public boolean isOverlaped(int x,
int y,
int width,
int height)
x - X axis coordinate.y - Y axis coordinate.width - Width.height - Height.public IntPoint[] getEdgePoints()