Java in a Nutshell Online Quick Reference for Java 1.1
Availability: JDK 1.0
public class Rectangle extends Object implements Shape, Serializable { // Public Constructors public Rectangle(); 1.1 public Rectangle(Rectangle r); public Rectangle(int x, int y, int width, int height); public Rectangle(int width, int height); public Rectangle(Point p, Dimension d); public Rectangle(Point p); public Rectangle(Dimension d); // Public Instance Variables public int height; public int width; public int x; public int y; // Public Instance Methods public void add(int newx, int newy); public void add(Point pt); public void add(Rectangle r); 1.1 public boolean contains(Point p); 1.1 public boolean contains(int x, int y); public boolean equals(Object obj); // Overrides Object.equals() 1.1 public Rectangle getBounds(); 1.1 public Point getLocation(); 1.1 public Dimension getSize(); public void grow(int h, int v); public int hashCode(); // Overrides Object.hashCode() # public boolean inside(int x, int y); public Rectangle intersection(Rectangle r); public boolean intersects(Rectangle r); public boolean isEmpty(); # public void move(int x, int y); # public void reshape(int x, int y, int width, int height); # public void resize(int width, int height); 1.1 public void setBounds(Rectangle r); 1.1 public void setBounds(int x, int y, int width, int height); 1.1 public void setLocation(Point p); 1.1 public void setLocation(int x, int y); 1.1 public void setSize(Dimension d); 1.1 public void setSize(int width, int height); public String toString(); // Overrides Object.toString() public void translate(int x, int y); public Rectangle union(Rectangle r); }