This patch (committed) adds some details to the API docs regarding null arguments
for a few methods that I happened to be looking at today:
2006-08-17 David Gilbert <[EMAIL PROTECTED]>
* java/util/Calendar.java: API doc additions.
Regards,
Dave
Index: java/util/Calendar.java
===================================================================
RCS file: /sources/classpath/classpath/java/util/Calendar.java,v
retrieving revision 1.49
diff -u -r1.49 Calendar.java
--- java/util/Calendar.java 7 May 2006 22:49:49 -0000 1.49
+++ java/util/Calendar.java 17 Aug 2006 12:22:29 -0000
@@ -1,5 +1,6 @@
/* Calendar.java --
- Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2005 Free Software
Foundation, Inc.
+ Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2005, 2006,
+ Free Software Foundation, Inc.
This file is part of GNU Classpath.
@@ -483,6 +484,8 @@
/**
* Creates a calendar representing the actual time, using the default
* time zone and locale.
+ *
+ * @return The new calendar.
*/
public static synchronized Calendar getInstance()
{
@@ -492,7 +495,12 @@
/**
* Creates a calendar representing the actual time, using the given
* time zone and the default locale.
- * @param zone a time zone.
+ *
+ * @param zone a time zone (<code>null</code> not permitted).
+ *
+ * @return The new calendar.
+ *
+ * @throws NullPointerException if <code>zone</code> is <code>null</code>.
*/
public static synchronized Calendar getInstance(TimeZone zone)
{
@@ -502,7 +510,12 @@
/**
* Creates a calendar representing the actual time, using the default
* time zone and the given locale.
- * @param locale a locale.
+ *
+ * @param locale a locale (<code>null</code> not permitted).
+ *
+ * @return The new calendar.
+ *
+ * @throws NullPointerException if <code>locale</code> is <code>null</code>.
*/
public static synchronized Calendar getInstance(Locale locale)
{
@@ -524,8 +537,14 @@
/**
* Creates a calendar representing the actual time, using the given
* time zone and locale.
- * @param zone a time zone.
- * @param locale a locale.
+ *
+ * @param zone a time zone (<code>null</code> not permitted).
+ * @param locale a locale (<code>null</code> not permitted).
+ *
+ * @return The new calendar.
+ *
+ * @throws NullPointerException if <code>zone</code> or <code>locale</code>
+ * is <code>null</code>.
*/
public static synchronized Calendar getInstance(TimeZone zone, Locale locale)
{
@@ -617,6 +636,10 @@
/**
* Sets this Calendar's time to the given Date. All time fields
* are invalidated by this method.
+ *
+ * @param date the date (<code>null</code> not permitted).
+ *
+ * @throws NullPointerException if <code>date</code> is <code>null</code>.
*/
public final void setTime(Date date)
{