org.htmlparser.lexerapplications.thumbelina
public class Picture extends Rectangle
Field Summary | |
---|---|
protected Image | mImage
The image for the picture. |
protected Point | mOrigin
The upper left hand corner of the image.
|
protected URL | mURL
The URL for the picture. |
static Point | ORIGIN
The origin for new points from the zero args constructor. |
Constructor Summary | |
---|---|
Picture()
Construct a Picture. | |
Picture(int x, int y, int width, int height)
Construct a Picture over the area given. | |
Picture(Rectangle r)
Construct a picture over the rectangle given. | |
Picture(Picture picture)
Construct a picture from the one given. |
Method Summary | |
---|---|
Image | getImage() Getter for property image. |
Point | getOrigin() Getter for property origin. |
URL | getURL()
Getter for property URL. |
void | reset()
Reset the picture to uncropped size. |
boolean | same(Picture picture)
Return true if that picture is the same as this one. |
void | setImage(Image image) Setter for property image. |
void | setOrigin(Point origin) Setter for property origin. |
void | setURL(URL url)
Setter for property URL. |
String | toString()
Create a string representation of the picture. |
Rectangle
fields x
, y
,
width
and height
will change, but the
origin remains the same.Parameters: x The x coordinate. y The y coordinate. width The width of the picture. height The height of the picture.
Parameters: r The coordinates of the area.
Parameters: picture The picture to copy.
Returns: Value of property image.
Returns: Value of property origin.
Returns: Value of property URL.
true
if that picture is the same as this one.Parameters: picture The picture to check.
Returns: true
if the images match.
Parameters: image New value of property image.
Parameters: origin New value of property origin.
Parameters: url New value of property URL.
Returns: A string that shows this picture URL and size.
HTML Parser is an open source library released under LGPL. | |