public class Rectangle
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
float |
bottom
Bottom edge of the rectangle.
|
float |
left
Left edge of the rectangle.
|
float |
right
Right edge of the rectangle.
|
float |
top
Top edge of the rectangle.
|
| Constructor and Description |
|---|
Rectangle(float l,
float r,
float t,
float b)
Create a Rectangle with the given edges.
|
public float left
public float right
public float top
public float bottom
public Rectangle(float l,
float r,
float t,
float b)
l - left edger - right edget - top edgeb - bottom edgepublic Rectangle encompass(Rectangle that)
that - other Rectanglepublic java.lang.String toString()
toString in class java.lang.Object