This patch (committed) fixes a couple of Eclipse warnings concerning the
API docs for GeneralPath:
2006-11-02 David Gilbert <[EMAIL PROTECTED]>
* java/awt/geom/GeneralPath.java: API doc fixes.
Regards,
Dave
Index: java/awt/geom/GeneralPath.java
===================================================================
RCS file: /sources/classpath/classpath/java/awt/geom/GeneralPath.java,v
retrieving revision 1.17
diff -u -r1.17 GeneralPath.java
--- java/awt/geom/GeneralPath.java 26 Jul 2006 20:32:06 -0000 1.17
+++ java/awt/geom/GeneralPath.java 2 Nov 2006 17:29:05 -0000
@@ -86,7 +86,7 @@
public static final int WIND_EVEN_ODD
= java.awt.geom.PathIterator.WIND_EVEN_ODD;
- /** Same constant as [EMAIL PROTECTED] PathIterator.WIND_NON_ZERO}. */
+ /** Same constant as [EMAIL PROTECTED] PathIterator#WIND_NON_ZERO}. */
public static final int WIND_NON_ZERO
= java.awt.geom.PathIterator.WIND_NON_ZERO;
@@ -140,7 +140,11 @@
/**
* 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 ([EMAIL PROTECTED] #WIND_NON_ZERO} or
+ * [EMAIL PROTECTED] #WIND_EVEN_ODD})
+ *
+ * @throws IllegalArgumentException if <code>rule</code> is not one of the
+ * listed values.
*/
public GeneralPath(int rule)
{
@@ -151,8 +155,12 @@
* 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 ([EMAIL PROTECTED] #WIND_NON_ZERO} or
+ * [EMAIL PROTECTED] #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 @@
/**
* 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 @@
/**
* 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 @@
* 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 @@
* 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
* [EMAIL PROTECTED] PathIterator#SEG_MOVETO} segment by a [EMAIL PROTECTED]
@@ -327,6 +346,8 @@
/**
* Returns the path’s current winding rule.
+ *
+ * @return [EMAIL PROTECTED] #WIND_EVEN_ODD} or [EMAIL PROTECTED]
#WIND_NON_ZERO}.
*/
public int getWindingRule()
{
@@ -338,6 +359,8 @@
* 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 ([EMAIL PROTECTED] #WIND_EVEN_ODD} or [EMAIL
PROTECTED] #WIND_NON_ZERO}).
*/
public void setWindingRule(int rule)
{
@@ -348,6 +371,8 @@
/**
* Returns the current appending point of the path.
+ *
+ * @return The point.
*/
public Point2D getCurrentPoint()
{
@@ -367,6 +392,8 @@
/**
* Applies a transform to the path.
+ *
+ * @param xform the transform (<code>null</code> not permitted).
*/
public void transform(AffineTransform xform)
{
@@ -706,6 +733,8 @@
/**
* 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)
{