Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

java.awt.geom
Class Arc2D.ArcIterator  view Arc2D.ArcIterator download Arc2D.ArcIterator.java

java.lang.Object
  extended byjava.awt.geom.Arc2D.ArcIterator
All Implemented Interfaces:
PathIterator
Enclosing class:
Arc2D

static final class Arc2D.ArcIterator
extends java.lang.Object
implements PathIterator

This class is used to iterate over an arc. Since ellipses are a subclass of arcs, this is used by Ellipse2D as well.


Field Summary
private  int current
          The current iteration.
private  double extent
          The extent angle, in radians (not degrees).
private  double h
          The height of the bounding box.
private  int limit
          The last iteration.
private  double start
          The start angle, in radians (not degrees).
private  int type
          The arc closure type.
private  double w
          The width of the bounding box.
private  double x
          The x coordinate of the bounding box.
private  AffineTransform xform
          The optional transformation.
private  double y
          The y coordinate of the bounding box.
 
Fields inherited from interface java.awt.geom.PathIterator
SEG_CLOSE, SEG_CUBICTO, SEG_LINETO, SEG_MOVETO, SEG_QUADTO, WIND_EVEN_ODD, WIND_NON_ZERO
 
Constructor Summary
Arc2D.ArcIterator(Arc2D a, AffineTransform xform)
          Construct a new iterator over an arc.
Arc2D.ArcIterator(Ellipse2D e, AffineTransform xform)
          Construct a new iterator over an ellipse.
 
Method Summary
 int currentSegment(double[] coords)
          Put the current segment into the array, and return the segment type.
 int currentSegment(float[] coords)
          Put the current segment into the array, and return the segment type.
 int getWindingRule()
          Return the winding rule.
 boolean isDone()
          Test if the iteration is complete.
 void next()
          Advance the iterator.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

current

private int current
The current iteration.


limit

private final int limit
The last iteration.


xform

private final AffineTransform xform
The optional transformation.


x

private final double x
The x coordinate of the bounding box.


y

private final double y
The y coordinate of the bounding box.


w

private final double w
The width of the bounding box.


h

private final double h
The height of the bounding box.


start

private final double start
The start angle, in radians (not degrees).


extent

private final double extent
The extent angle, in radians (not degrees).


type

private final int type
The arc closure type.

Constructor Detail

Arc2D.ArcIterator

public Arc2D.ArcIterator(Arc2D a,
                         AffineTransform xform)
Construct a new iterator over an arc.


Arc2D.ArcIterator

public Arc2D.ArcIterator(Ellipse2D e,
                         AffineTransform xform)
Construct a new iterator over an ellipse.

Method Detail

getWindingRule

public int getWindingRule()
Return the winding rule.

Specified by:
getWindingRule in interface PathIterator

isDone

public boolean isDone()
Test if the iteration is complete.

Specified by:
isDone in interface PathIterator

next

public void next()
Advance the iterator.

Specified by:
next in interface PathIterator

currentSegment

public int currentSegment(float[] coords)
Put the current segment into the array, and return the segment type.

Specified by:
currentSegment in interface PathIterator

currentSegment

public int currentSegment(double[] coords)
Put the current segment into the array, and return the segment type.

Specified by:
currentSegment in interface PathIterator