Commit c05fc0c2 by Michael Koch Committed by Michael Koch

2003-12-19 Michael Koch <konqueror@gmx.de>

	* java/util/SimpleTimeZone.java
	(setStartRule): Reformated documentation.
	(setEndRule): Reworked documentation.
	(getDSTSavings): Fixed @since tag.
	(setDSTSavings): New method.

From-SVN: r74831
parent b2fbbf56
2003-12-19 Michael Koch <konqueror@gmx.de> 2003-12-19 Michael Koch <konqueror@gmx.de>
* java/util/SimpleTimeZone.java
(setStartRule): Reformated documentation.
(setEndRule): Reworked documentation.
(getDSTSavings): Fixed @since tag.
(setDSTSavings): New method.
2003-12-19 Michael Koch <konqueror@gmx.de>
* java/text/NumberFormat.java: Sorted imports. * java/text/NumberFormat.java: Sorted imports.
(getCurrency): New method. (getCurrency): New method.
(setCurrency): New method. (setCurrency): New method.
......
/* java.util.SimpleTimeZone /* java.util.SimpleTimeZone
Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc. Copyright (C) 1998, 1999, 2000, 2003 Free Software Foundation, Inc.
This file is part of GNU Classpath. This file is part of GNU Classpath.
...@@ -390,7 +390,8 @@ public class SimpleTimeZone extends TimeZone ...@@ -390,7 +390,8 @@ public class SimpleTimeZone extends TimeZone
* @param dayOfWeek The day of week where daylight savings start. * @param dayOfWeek The day of week where daylight savings start.
* @param time The time in milliseconds standard time where daylight * @param time The time in milliseconds standard time where daylight
* savings start. * savings start.
* @see SimpleTimeZone */ * @see SimpleTimeZone
*/
public void setStartRule(int month, int day, int dayOfWeek, int time) public void setStartRule(int month, int day, int dayOfWeek, int time)
{ {
this.startMode = checkRule(month, day, dayOfWeek); this.startMode = checkRule(month, day, dayOfWeek);
...@@ -411,11 +412,12 @@ public class SimpleTimeZone extends TimeZone ...@@ -411,11 +412,12 @@ public class SimpleTimeZone extends TimeZone
* *
* @param rawOffset The time offset from GMT. * @param rawOffset The time offset from GMT.
* @param id The identifier of this time zone. * @param id The identifier of this time zone.
* @param Month The end month of daylight savings. * @param month The end month of daylight savings.
* @param day A day in month, or a day of week in month. * @param day A day in month, or a day of week in month.
* @param DayOfWeek A day of week, when daylight savings ends. * @param dayOfWeek A day of week, when daylight savings ends.
* @param Time A time in millis in standard time. * @param time A time in millis in standard time.
* @see #setStartRule */ * @see #setStartRule
*/
public void setEndRule(int month, int day, int dayOfWeek, int time) public void setEndRule(int month, int day, int dayOfWeek, int time)
{ {
this.endMode = checkRule(month, day, dayOfWeek); this.endMode = checkRule(month, day, dayOfWeek);
...@@ -509,7 +511,7 @@ public class SimpleTimeZone extends TimeZone ...@@ -509,7 +511,7 @@ public class SimpleTimeZone extends TimeZone
* is one hour, but for some time zones this may be half an our. * is one hour, but for some time zones this may be half an our.
* @return the daylight savings offset in milliseconds. * @return the daylight savings offset in milliseconds.
* *
* @since JDK1.2 * @since 1.2
*/ */
public int getDSTSavings() public int getDSTSavings()
{ {
...@@ -517,6 +519,22 @@ public class SimpleTimeZone extends TimeZone ...@@ -517,6 +519,22 @@ public class SimpleTimeZone extends TimeZone
} }
/** /**
* Sets the daylight savings offset. This is a positive offset in
* milliseconds with respect to standard time.
*
* @param dstSavings the daylight savings offset in milliseconds.
*
* @since 1.2
*/
public void setDSTSavings(int dstSavings)
{
if (dstSavings <= 0)
throw new IllegalArgumentException("illegal value for dstSavings");
this.dstSavings = dstSavings;
}
/**
* Returns if this time zone uses daylight savings time. * Returns if this time zone uses daylight savings time.
* @return true, if we use daylight savings time, false otherwise. * @return true, if we use daylight savings time, false otherwise.
*/ */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment