|
Apime v1.0 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.java4ever.apime.math.Point
com.java4ever.apime.math.Rectangle
Rectángulo.
| Field Summary | |
int |
height
Alto. |
int |
width
Ancho. |
| Fields inherited from class com.java4ever.apime.math.Point |
x, y |
| Constructor Summary | |
Rectangle()
Crea un rectángulo. |
|
Rectangle(int x,
int y,
int width,
int height)
Crea un rectángulo. |
|
Rectangle(Rectangle r)
Crea un rectángulo. |
|
| Method Summary | |
boolean |
contains(int x,
int y)
Comprueba si contiene las coordenadas indicadas. |
boolean |
contains(Point p)
Comprueba si contiene las coordenadas indicadas. |
Rectangle |
intersection(Rectangle r)
Calcula la intersección con otro rectángulo. |
Rectangle |
intersection(Rectangle r,
Rectangle dst)
Calcula la intersección con otro rectángulo. |
boolean |
intersects(Rectangle r)
Comprueba si hay intersección con otro rectángulo. |
void |
setBounds(int x,
int y,
int width,
int height)
Cambia las coordenadas y el tamaño del rectángulo. |
void |
setBounds(Rectangle r)
Cambia las coordenadas y el tamaño del rectángulo. |
void |
setSize(int width,
int height)
Cambia el tamaño del rectángulo. |
java.lang.String |
toString()
|
| Methods inherited from class com.java4ever.apime.math.Point |
setLocation, setLocation |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public int width
public int height
| Constructor Detail |
public Rectangle()
public Rectangle(int x,
int y,
int width,
int height)
x - Coordenada Xy - Coordenada Ywidth - Anchoheight - Altopublic Rectangle(Rectangle r)
r - Rectángulo que contiene los datos| Method Detail |
public void setSize(int width,
int height)
width - Anchoheight - Alto
public void setBounds(int x,
int y,
int width,
int height)
x - Coordenada Xy - Coordenada Ywidth - Anchoheight - Altopublic void setBounds(Rectangle r)
r - Rectángulo que contiene los datos
public boolean contains(int x,
int y)
x - Coordenada Xy - Coordenada Y
public boolean contains(Point p)
p - Coordenadas
Pointpublic boolean intersects(Rectangle r)
r - Rectángulo
public Rectangle intersection(Rectangle r)
r - Rectángulo
public Rectangle intersection(Rectangle r,
Rectangle dst)
r - Rectángulodst - Rectángulo donde almacena los datos de la intersección
public java.lang.String toString()
toString in class Point
|
Apime v1.0 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||