diff options
author | Andrew John Hughes <gnu_andrew@member.fsf.org> | 2006-11-04 18:55:49 +0000 |
---|---|---|
committer | Andrew John Hughes <gnu_andrew@member.fsf.org> | 2006-11-04 18:55:49 +0000 |
commit | 237bdd93058f891ae4567cf4e051c5831bd4646b (patch) | |
tree | 61bf13ecf1942efef4ef00642e2ff0f4318a9fb7 /java/awt/geom/GeneralPath.java | |
parent | e36d2a50b5a1a677c7ecaf926e73a5dac386c1ef (diff) | |
download | classpath-237bdd93058f891ae4567cf4e051c5831bd4646b.tar.gz |
2006-11-04 Andrew John Hughes <gnu_andrew@member.fsf.org>
* Merge of HEAD-->generics-branch for 2006/10/29 to 2006/11/04.
Diffstat (limited to 'java/awt/geom/GeneralPath.java')
-rw-r--r-- | java/awt/geom/GeneralPath.java | 39 |
1 files changed, 34 insertions, 5 deletions
diff --git a/java/awt/geom/GeneralPath.java b/java/awt/geom/GeneralPath.java index e0ca8e183..1e9ede5ee 100644 --- a/java/awt/geom/GeneralPath.java +++ b/java/awt/geom/GeneralPath.java @@ -86,7 +86,7 @@ public final class GeneralPath implements Shape, Cloneable public static final int WIND_EVEN_ODD = java.awt.geom.PathIterator.WIND_EVEN_ODD; - /** Same constant as {@link PathIterator.WIND_NON_ZERO}. */ + /** Same constant as {@link PathIterator#WIND_NON_ZERO}. */ public static final int WIND_NON_ZERO = java.awt.geom.PathIterator.WIND_NON_ZERO; @@ -140,7 +140,11 @@ public final class GeneralPath implements Shape, Cloneable /** * Constructs a GeneralPath with a specific winding rule * and the default initial capacity (20). - * @param rule the winding rule (WIND_NON_ZERO or WIND_EVEN_ODD) + * @param rule the winding rule ({@link #WIND_NON_ZERO} or + * {@link #WIND_EVEN_ODD}) + * + * @throws IllegalArgumentException if <code>rule</code> is not one of the + * listed values. */ public GeneralPath(int rule) { @@ -151,8 +155,12 @@ public final class GeneralPath implements Shape, Cloneable * Constructs a GeneralPath with a specific winding rule * and the initial capacity. The initial capacity should be * the approximate number of path segments to be used. - * @param rule the winding rule (WIND_NON_ZERO or WIND_EVEN_ODD) + * @param rule the winding rule ({@link #WIND_NON_ZERO} or + * {@link #WIND_EVEN_ODD}) * @param capacity the inital capacity, in path segments + * + * @throws IllegalArgumentException if <code>rule</code> is not one of the + * listed values. */ public GeneralPath(int rule, int capacity) { @@ -169,7 +177,10 @@ public final class GeneralPath implements Shape, Cloneable /** * Constructs a GeneralPath from an arbitrary shape object. * The Shapes PathIterator path and winding rule will be used. - * @param s the shape + * + * @param s the shape (<code>null</code> not permitted). + * + * @throws NullPointerException if <code>shape</code> is <code>null</code>. */ public GeneralPath(Shape s) { @@ -183,6 +194,9 @@ public final class GeneralPath implements Shape, Cloneable /** * Adds a new point to a path. + * + * @param x the x-coordinate. + * @param y the y-coordinate. */ public void moveTo(float x, float y) { @@ -263,6 +277,11 @@ public final class GeneralPath implements Shape, Cloneable * Appends the segments of a Shape to the path. If <code>connect</code> is * true, the new path segments are connected to the existing one with a line. * The winding rule of the Shape is ignored. + * + * @param s the shape (<code>null</code> not permitted). + * @param connect whether to connect the new shape to the existing path. + * + * @throws NullPointerException if <code>s</code> is <code>null</code>. */ public void append(Shape s, boolean connect) { @@ -276,7 +295,7 @@ public final class GeneralPath implements Shape, Cloneable * PathIterator#SEG_LINETO} segment. * * @param iter the PathIterator specifying which segments shall be - * appended. + * appended (<code>null</code> not permitted). * * @param connect <code>true</code> for substituting the initial * {@link PathIterator#SEG_MOVETO} segment by a {@link @@ -327,6 +346,8 @@ public final class GeneralPath implements Shape, Cloneable /** * Returns the path’s current winding rule. + * + * @return {@link #WIND_EVEN_ODD} or {@link #WIND_NON_ZERO}. */ public int getWindingRule() { @@ -338,6 +359,8 @@ public final class GeneralPath implements Shape, Cloneable * considered ’inside’ or ’outside’ the path * on drawing. Valid rules are WIND_EVEN_ODD for an even-odd winding rule, * or WIND_NON_ZERO for a non-zero winding rule. + * + * @param rule the rule ({@link #WIND_EVEN_ODD} or {@link #WIND_NON_ZERO}). */ public void setWindingRule(int rule) { @@ -348,6 +371,8 @@ public final class GeneralPath implements Shape, Cloneable /** * Returns the current appending point of the path. + * + * @return The point. */ public Point2D getCurrentPoint() { @@ -367,6 +392,8 @@ public final class GeneralPath implements Shape, Cloneable /** * Applies a transform to the path. + * + * @param xform the transform (<code>null</code> not permitted). */ public void transform(AffineTransform xform) { @@ -706,6 +733,8 @@ public final class GeneralPath implements Shape, Cloneable /** * Helper method - ensure the size of the data arrays, * otherwise, reallocate new ones twice the size + * + * @param size the minimum array size. */ private void ensureSize(int size) { |