Java in a Nutshell Online Quick Reference for Java 1.1

CLASS java.awt.Polygon

Availability: JDK 1.0

public class Polygon extends Object implements Shape, Serializable {
   // Public Constructors
      public Polygon();
      public Polygon(int[] xpoints, int[] ypoints, int npoints);
   // Public Instance Variables
      public int npoints;
      public int[] xpoints;
      public int[] ypoints;
   // Protected Instance Variables
      protected Rectangle bounds;
   // Public Instance Methods
      public void addPoint(int x, int y);
1.1  public boolean contains(Point p);
1.1  public boolean contains(int x, int y);
#    public Rectangle getBoundingBox();
1.1  public Rectangle getBounds();
#    public boolean inside(int x, int y);
1.1  public void translate(int deltaX, int deltaY);
}
Passed To:
Graphics.drawPolygon(), Graphics.fillPolygon().

Java in a Nutshell Online Quick Reference for Java 1.1
Created by David Flanagan. Copyright © 1997 by O'Reilly & Associates.