⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 simpletimezone.html

📁 API資料大全
💻 HTML
📖 第 1 页 / 共 3 页
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN""http://www.w3.org/TR/REC-html40/frameset.dtd"><!--NewPage--><HTML><HEAD><!-- Generated by javadoc on Thu Apr 27 23:37:00 PDT 2000 --><TITLE>Java 2 Platform SE v1.3: Class  SimpleTimeZone</TITLE><LINK REL ="stylesheet" TYPE="text/css" HREF="../../stylesheet.css" TITLE="Style"></HEAD><BODY BGCOLOR="white"><!-- ========== START OF NAVBAR ========== --><A NAME="navbar_top"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0"><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_top_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">  <TR ALIGN="center" VALIGN="top">  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/SimpleTimeZone.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>  </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM><b>Java<sup><font size=-2>TM</font></sup>&nbsp;2&nbsp;Platform<br>Std.&nbsp;Ed. v1.3</b></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">&nbsp;<A HREF="../../java/util/ResourceBundle.html"><B>PREV CLASS</B></A>&nbsp;&nbsp;<A HREF="../../java/util/Stack.html"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="../../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="SimpleTimeZone.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">  SUMMARY: &nbsp;INNER&nbsp;|&nbsp;<A HREF="#fields_inherited_from_class_java.util.TimeZone">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: &nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><!-- =========== END OF NAVBAR =========== --><HR><!-- ======== START OF CLASS DATA ======== --><H2><FONT SIZE="-1">java.util</FONT><BR>Class  SimpleTimeZone</H2><PRE><A HREF="../../java/lang/Object.html">java.lang.Object</A>  |  +--<A HREF="../../java/util/TimeZone.html">java.util.TimeZone</A>        |        +--<B>java.util.SimpleTimeZone</B></PRE><DL><DT><B>All Implemented Interfaces:</B> <DD><A HREF="../../java/lang/Cloneable.html">Cloneable</A>, <A HREF="../../java/io/Serializable.html">Serializable</A></DD></DL><HR><DL><DT>public class <B>SimpleTimeZone</B><DT>extends <A HREF="../../java/util/TimeZone.html">TimeZone</A></DL><P><code>SimpleTimeZone</code> is a concrete subclass of <code>TimeZone</code> that represents a time zone for use with a Gregorian calendar. This class does not handle historical changes. <P> Use a negative value for <code>dayOfWeekInMonth</code> to indicate that <code>SimpleTimeZone</code> should count from the end of the month backwards. For example, Daylight Savings Time ends at the last (dayOfWeekInMonth = -1) Sunday in October, at 2 AM in standard time.<P><DL><DT><B>See Also: </B><DD><A HREF="../../java/util/Calendar.html"><CODE>Calendar</CODE></A>, <A HREF="../../java/util/GregorianCalendar.html"><CODE>GregorianCalendar</CODE></A>, <A HREF="../../java/util/TimeZone.html"><CODE>TimeZone</CODE></A>, <A HREF="../../serialized-form.html#java.util.SimpleTimeZone">Serialized Form</A></DL><HR><P><!-- ======== INNER CLASS SUMMARY ======== --><!-- =========== FIELD SUMMARY =========== --><A NAME="fields_inherited_from_class_java.util.TimeZone"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Fields inherited from class java.util.<A HREF="../../java/util/TimeZone.html">TimeZone</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="../../java/util/TimeZone.html#LONG">LONG</A>, <A HREF="../../java/util/TimeZone.html#SHORT">SHORT</A></CODE></TD></TR></TABLE>&nbsp;<!-- ======== CONSTRUCTOR SUMMARY ======== --><A NAME="constructor_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=2><FONT SIZE="+2"><B>Constructor Summary</B></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#SimpleTimeZone(int, java.lang.String)">SimpleTimeZone</A></B>(int&nbsp;rawOffset,               <A HREF="../../java/lang/String.html">String</A>&nbsp;ID)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs a SimpleTimeZone with the given base time zone offset from GMT and time zone ID.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#SimpleTimeZone(int, java.lang.String, int, int, int, int, int, int, int, int)">SimpleTimeZone</A></B>(int&nbsp;rawOffset,               <A HREF="../../java/lang/String.html">String</A>&nbsp;ID,               int&nbsp;startMonth,               int&nbsp;startDay,               int&nbsp;startDayOfWeek,               int&nbsp;startTime,               int&nbsp;endMonth,               int&nbsp;endDay,               int&nbsp;endDayOfWeek,               int&nbsp;endTime)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Construct a SimpleTimeZone with the given base time zone offset from GMT, time zone ID, time to start and end the daylight time.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#SimpleTimeZone(int, java.lang.String, int, int, int, int, int, int, int, int, int)">SimpleTimeZone</A></B>(int&nbsp;rawOffset,               <A HREF="../../java/lang/String.html">String</A>&nbsp;ID,               int&nbsp;startMonth,               int&nbsp;startDay,               int&nbsp;startDayOfWeek,               int&nbsp;startTime,               int&nbsp;endMonth,               int&nbsp;endDay,               int&nbsp;endDayOfWeek,               int&nbsp;endTime,               int&nbsp;dstSavings)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructor.</TD></TR></TABLE>&nbsp;<!-- ========== METHOD SUMMARY =========== --><A NAME="method_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=2><FONT SIZE="+2"><B>Method Summary</B></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../java/lang/Object.html">Object</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#clone()">clone</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Overrides Cloneable</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#equals(java.lang.Object)">equals</A></B>(<A HREF="../../java/lang/Object.html">Object</A>&nbsp;obj)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Compares the equality of two SimpleTimeZone objects.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#getDSTSavings()">getDSTSavings</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the amount of time in ms that the clock is advanced during DST.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#getOffset(int, int, int, int, int, int)">getOffset</A></B>(int&nbsp;era,          int&nbsp;year,          int&nbsp;month,          int&nbsp;day,          int&nbsp;dayOfWeek,          int&nbsp;millis)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the difference in milliseconds between local time and UTC, taking into account both the raw offset and the effect of daylight savings, for the specified date and time.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#getRawOffset()">getRawOffset</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Overrides TimeZone Gets the GMT offset for this time zone.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#hashCode()">hashCode</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Override hashCode.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#hasSameRules(java.util.TimeZone)">hasSameRules</A></B>(<A HREF="../../java/util/TimeZone.html">TimeZone</A>&nbsp;other)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Return true if this zone has the same rules and offset as another zone.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#inDaylightTime(java.util.Date)">inDaylightTime</A></B>(<A HREF="../../java/util/Date.html">Date</A>&nbsp;date)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Overrides TimeZone Queries if the given date is in Daylight Savings Time.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#setDSTSavings(int)">setDSTSavings</A></B>(int&nbsp;millisSavedDuringDST)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the amount of time in ms that the clock is advanced during DST.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#setEndRule(int, int, int)">setEndRule</A></B>(int&nbsp;month,           int&nbsp;dayOfMonth,           int&nbsp;time)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the DST end rule to a fixed date within a month.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#setEndRule(int, int, int, int)">setEndRule</A></B>(int&nbsp;month,           int&nbsp;dayOfWeekInMonth,           int&nbsp;dayOfWeek,           int&nbsp;time)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the daylight savings ending rule.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#setEndRule(int, int, int, int, boolean)">setEndRule</A></B>(int&nbsp;month,           int&nbsp;dayOfMonth,           int&nbsp;dayOfWeek,           int&nbsp;time,           boolean&nbsp;after)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the DST end rule to a weekday before or after a give date within a month, e.g., the first Monday on or after the 8th.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#setRawOffset(int)">setRawOffset</A></B>(int&nbsp;offsetMillis)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Overrides TimeZone Sets the base time zone offset to GMT.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../java/util/SimpleTimeZone.html#setStartRule(int, int, int)">setStartRule</A></B>(int&nbsp;month,             int&nbsp;dayOfMonth,             int&nbsp;time)</CODE>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -