API Overview API Index Package Overview Direct link to this page
JDK 1.6
  java.awt.geom. Arc2D View Source
Author(s)
Jim Graham
Since
1.2
Version
10 Feb 1997
Serial
Hierarchy
 Object
      RectangularShape
          Arc2D
Implements
Subclasses
Description
publicabstract abstract class Arc2D
  Arc2D is the abstract superclass for all objects that store a 2D arc defined by a framing rectangle, start angle, angular extent (length of the arc), and a closure type (OPEN, CHORD, or PIE).
See also:   
Constructors
pack-private Arc2D ()
  This is an abstract class that cannot be instantiated directly.
protected Arc2D (int type)
  This is an abstract class that cannot be instantiated directly.
Methods
Hide/Show inherited methods
public Object clone () [Inherited From RectangularShape]
  Creates a new object of the same class and with the same contents as this object.
public boolean contains (double x, double y)
  Determines whether or not the specified point is inside the boundary of the arc.
public boolean contains (double x, double y, double w, double h)
  Determines whether or not the interior of the arc entirely contains the specified rectangle.
public boolean contains (Point2D p) [Inherited From RectangularShape]
  Tests if a specified Point2D is inside the boundary of the Shape.
public boolean contains (Rectangle2D r) [Overrides RectangularShape]
  Determines whether or not the interior of the arc entirely contains the specified rectangle.
public boolean containsAngle (double angle)
  Determines whether or not the specified angle is within the angular extents of the arc.
public boolean equals (Object obj)
  Determines whether or not the specified Object is equal to this Arc2D.
publicabstract double getAngleExtent ()
  Returns the angular extent of the arc.
publicabstract double getAngleStart ()
  Returns the starting angle of the arc.
public int getArcType ()
  Returns the arc closure type of the arc: Arc2D.OPEN, Arc2D.CHORD, or Arc2D.PIE.
public Rectangle getBounds () [Inherited From RectangularShape]
  Returns an integer Rectangle that completely encloses the Shape.
public Rectangle2D getBounds2D ()
  Returns the high-precision framing rectangle of the arc.
public double getCenterX () [Inherited From RectangularShape]
  Returns the X coordinate of the center of the framing rectangle of the Shape in double precision.
public double getCenterY () [Inherited From RectangularShape]
  Returns the Y coordinate of the center of the framing rectangle of the Shape in double precision.
public Point2D getEndPoint ()
  Returns the ending point of the arc.
public Rectangle2D getFrame () [Inherited From RectangularShape]
  Returns the framing Rectangle2D that defines the overall shape of this object.
publicabstract double getHeight () [Inherited From RectangularShape]
  Returns the height of the framing rectangle in double precision.
public double getMaxX () [Inherited From RectangularShape]
  Returns the largest X coordinate of the framing rectangle of the Shape in double precision.
public double getMaxY () [Inherited From RectangularShape]
  Returns the largest Y coordinate of the framing rectangle of the Shape in double precision.
public double getMinX () [Inherited From RectangularShape]
  Returns the smallest X coordinate of the framing rectangle of the Shape in double precision.
public double getMinY () [Inherited From RectangularShape]
  Returns the smallest Y coordinate of the framing rectangle of the Shape in double precision.
public PathIterator getPathIterator (AffineTransform at)
  Returns an iteration object that defines the boundary of the arc.
public PathIterator getPathIterator (AffineTransform at, double flatness) [Inherited From RectangularShape]
  Returns an iterator object that iterates along the Shape object's boundary and provides access to a flattened view of the outline of the Shape object's geometry.
public Point2D getStartPoint ()
  Returns the starting point of the arc.
publicabstract double getWidth () [Inherited From RectangularShape]
  Returns the width of the framing rectangle in double precision.
publicabstract double getX () [Inherited From RectangularShape]
  Returns the X coordinate of the upper-left corner of the framing rectangle in double precision.
publicabstract double getY () [Inherited From RectangularShape]
  Returns the Y coordinate of the upper-left corner of the framing rectangle in double precision.
public int hashCode ()
  Returns the hashcode for this Arc2D.
public boolean intersects (double x, double y, double w, double h)
  Determines whether or not the interior of the arc intersects the interior of the specified rectangle.
public boolean intersects (Rectangle2D r) [Inherited From RectangularShape]
  Tests if the interior of the Shape intersects the interior of a specified Rectangle2D.
publicabstract boolean isEmpty () [Inherited From RectangularShape]
  Determines whether the RectangularShape is empty.
protectedabstract Rectangle2D makeBounds (double x, double y, double w, double h)
  Constructs a Rectangle2D of the appropriate precision to hold the parameters calculated to be the framing rectangle of this arc.
pack-privatestatic double normalizeDegrees (double angle)
publicabstract void setAngleExtent (double angExt)
  Sets the angular extent of this arc to the specified double value.
public void setAngles (double x1, double y1, double x2, double y2)
  Sets the starting angle and angular extent of this arc using two sets of coordinates.
public void setAngles (Point2D p1, Point2D p2)
  Sets the starting angle and angular extent of this arc using two points.
publicabstract void setAngleStart (double angSt)
  Sets the starting angle of this arc to the specified double value.
public void setAngleStart (Point2D p)
  Sets the starting angle of this arc to the angle that the specified point defines relative to the center of this arc.
public void setArc (Arc2D a)
  Sets this arc to be the same as the specified arc.
publicabstract void setArc (double x, double y, double w, double h, double angSt, double angExt, int closure)
  Sets the location, size, angular extents, and closure type of this arc to the specified double values.
public void setArc (Point2D loc, Dimension2D size, double angSt, double angExt, int closure)
  Sets the location, size, angular extents, and closure type of this arc to the specified values.
public void setArc (Rectangle2D rect, double angSt, double angExt, int closure)
  Sets the location, size, angular extents, and closure type of this arc to the specified values.
public void setArcByCenter (double x, double y, double radius, double angSt, double angExt, int closure)
  Sets the position, bounds, angular extents, and closure type of this arc to the specified values.
public void setArcByTangent (Point2D p1, Point2D p2, Point2D p3, double radius)
  Sets the position, bounds, and angular extents of this arc to the specified value.
public void setArcType (int type)
  Sets the closure type of this arc to the specified value: OPEN, CHORD, or PIE.
public void setFrame (double x, double y, double w, double h) [Specified in RectangularShape]
  Sets the location and size of the framing rectangle of this Shape to the specified rectangular values. Note that the arc partially inscribes the framing rectangle of this RectangularShape.
public void setFrame (Point2D loc, Dimension2D size) [Inherited From RectangularShape]
  Sets the location and size of the framing rectangle of this Shape to the specified Point2D and Dimension2D, respectively.
public void setFrame (Rectangle2D r) [Inherited From RectangularShape]
  Sets the framing rectangle of this Shape to be the specified Rectangle2D.
public void setFrameFromCenter (double centerX, double centerY, double cornerX, double cornerY) [Inherited From RectangularShape]
  Sets the framing rectangle of this Shape based on the specified center point coordinates and corner point coordinates.
public void setFrameFromCenter (Point2D center, Point2D corner) [Inherited From RectangularShape]
  Sets the framing rectangle of this Shape based on a specified center Point2D and corner Point2D.
public void setFrameFromDiagonal (double x1, double y1, double x2, double y2) [Inherited From RectangularShape]
  Sets the diagonal of the framing rectangle of this Shape based on the two specified coordinates.
public void setFrameFromDiagonal (Point2D p1, Point2D p2) [Inherited From RectangularShape]
  Sets the diagonal of the framing rectangle of this Shape based on two specified Point2D objects.
Fields
Hide/Show inherited fields
publicfinalstatic int CHORD = "1"
  The closure type for an arc closed by drawing a straight line segment from the start of the arc segment to the end of the arc segment.
publicfinalstatic int OPEN = "0"
  The closure type for an open arc with no path segments connecting the two ends of the arc segment.
publicfinalstatic int PIE = "2"
  The closure type for an arc closed by drawing straight line segments from the start of the arc segment to the center of the full ellipse and from that point to the end of the arc segment.
Nested Classes
  Arc2D.Float
This class defines an arc specified in float precision.
  Arc2D.Double
This class defines an arc specified in double precision.
Generated By: JavaOnTracks Doclet 0.1.4     ©Thibaut Colar