From affe6f69d1b62bd4c56c9f3fa5d72430a3847253 Mon Sep 17 00:00:00 2001 From: Michael Koch Date: Mon, 10 Jan 2005 18:26:40 +0000 Subject: [multiple changes] 2005-01-10 Michael Koch * java/util/SimpleTimeZone.java (checkRule): Throw IllegalArgumentException on invalid month values. * java/util/TimeZone.java (setID): Throw NullPointerException if needed. 2005-01-10 Andrew John Hughes * java/util/SimpleTimeZone.java (getOffset): offset end date with daylight savings From-SVN: r93149 --- libjava/java/util/TimeZone.java | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'libjava/java/util/TimeZone.java') diff --git a/libjava/java/util/TimeZone.java b/libjava/java/util/TimeZone.java index 39cdcd3e239..0685e604600 100644 --- a/libjava/java/util/TimeZone.java +++ b/libjava/java/util/TimeZone.java @@ -989,9 +989,13 @@ public abstract class TimeZone implements java.io.Serializable, Cloneable * Sets the identifier of this time zone. For instance, PST for * Pacific Standard Time. * @param id the new time zone ID. + * @throws NullPointerException if id is null */ public void setID(String id) { + if (id == null) + throw new NullPointerException(); + this.ID = id; } -- cgit v1.2.3