[ Mini Kiebo ]
Server: Windows NT DESKTOP-5B8S0D4 6.2 build 9200 (Windows 8 Professional Edition) i586
Path:
D:
/
xampp182
/
htdocs
/
simpeg
/
zapatec
/
zpcal
/
zpcal
/
jsdocs
/
[
Home
]
File: Date.html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN""http://www.w3.org/TR/REC-html40/loose.dtd"> <!--NewPage--> <HTML> <HEAD> <TITLE> Date </TITLE> <LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style"> </HEAD> <SCRIPT> function asd() { parent.document.title="Date"; } </SCRIPT> <BODY BGCOLOR="white" onload="asd();"> <!-- ========== START OF NAVBAR ========== --> <A NAME="navbar_bottom"><!-- --></A> <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0"> <TR> <TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A NAME="navbar_bottom_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> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">File</FONT> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <!--TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"--> <!--A HREF="deprecated-list.html"--><!--FONT CLASS="NavBarFont1">Deprecated</FONT--><!--/A--><!-- </TD--> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"--><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR> </TABLE> </TD> <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM> <B>Zapatec Calendar</B> </EM> </TD </TR> <TR> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <B>PREV CLASS</B><!-- NEXT CLASS --> <A HREF="Zapatec/Calendar.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> <A HREF="" TARGET="_top"><B>NO FRAMES</B></A> <SCRIPT> <!-- if(window==top) { document.writeln('<A HREF="allclasses-noframe.html" TARGET=""><B>All Classes</B></A>'); } //--> </SCRIPT> <NOSCRIPT> <A HREF="allclasses-noframe.html" TARGET=""><B>All Classes</B></A> </NOSCRIPT> </FONT></TD> </TR> <TR> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD> </TR> </TABLE> <!-- =========== END OF NAVBAR =========== --> <HR> <!-- ======== START OF CLASS DATA ======== --> <H2>Class Date</H2> <PRE>Object | +--<b>Date</b> </PRE> <HR> <DL> <!-- Class definition --> <DT>class <B>Date</B> </DL> <HR> <!-- ======== NESTED CLASS SUMMARY ======== --> <!-- ======== END NESTED CLASS SUMMARY ======== --> <!-- =========== FIELD SUMMARY =========== --> <A NAME="field_summary"><!-- --></A> <TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TD COLSPAN=2><FONT SIZE="+2"> <B>Field Summary</B></FONT></TD> </TR> <!-- This is one instance field summary --> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE> Object</CODE></FONT></TD> <TD><CODE><B><A HREF="#__msh_oldSetFullYear">__msh_oldSetFullYear</A></B></CODE> <BR> </TD> </TR> </TABLE> <!-- =========== END FIELD SUMMARY =========== --> <!-- ======== CONSTRUCTOR SUMMARY ======== --> <!-- ======== END CONSTRUCTOR SUMMARY ======== --> <!-- ========== 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> Object</CODE> </FONT> </TD> <TD> <CODE> <B> <A HREF="#compareDatesOnly">compareDatesOnly</A></B>(date1,date2) </CODE> <BR> This function compares only years, months and days of two date objects. </TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"> <FONT SIZE="-1"> <CODE> Object</CODE> </FONT> </TD> <TD> <CODE> <B> <A HREF="#dateEqualsTo">dateEqualsTo</A></B>(date) </CODE> <BR> Checks dates equality. </TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"> <FONT SIZE="-1"> <CODE> Object</CODE> </FONT> </TD> <TD> <CODE> <B> <A HREF="#equalsTo">equalsTo</A></B>(date) </CODE> <BR> Checks dates equality. </TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"> <FONT SIZE="-1"> <CODE> Object</CODE> </FONT> </TD> <TD> <CODE> <B> <A HREF="#getDayOfYear">getDayOfYear</A></B>() </CODE> <BR> Returns the number of the current day in the current year. </TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"> <FONT SIZE="-1"> <CODE> Object</CODE> </FONT> </TD> <TD> <CODE> <B> <A HREF="#getMonthDays">getMonthDays</A></B>(month) </CODE> <BR> Returns the number of days in the month. </TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"> <FONT SIZE="-1"> <CODE> Object</CODE> </FONT> </TD> <TD> <CODE> <B> <A HREF="#getWeekNumber">getWeekNumber</A></B>() </CODE> <BR> Returns the number of the week in year, as defined in ISO 8601. </TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"> <FONT SIZE="-1"> <CODE> Object</CODE> </FONT> </TD> <TD> <CODE> <B> <A HREF="#print">print</A></B>(str) </CODE> <BR> Prints the date in a string according to the given format. </TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"> <FONT SIZE="-1"> <CODE> void</CODE> </FONT> </TD> <TD> <CODE> <B> <A HREF="#setDateOnly">setDateOnly</A></B>(date) </CODE> <BR> Set only the year, month, date parts (keep existing time) </TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"> <FONT SIZE="-1"> <CODE> void</CODE> </FONT> </TD> <TD> <CODE> <B> <A HREF="#setFullYear">setFullYear</A></B>(y) </CODE> <BR> This function replaces the original Date.setFullYear() with a "safer" function which makes sure that the month or date aren't modified (unless in the exceptional case where the date is February 29 but the new year doesn't contain it). </TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"> <FONT SIZE="-1"> <CODE><static> Object</CODE> </FONT> </TD> <TD> <CODE> <B> <A HREF="#!s!parseDate">parseDate</A></B>(str, format) </CODE> <BR> Parses a date from a string in the specified format. </TD> </TR> </TABLE> <P> <!-- ========== END METHOD SUMMARY =========== --> <!-- ============ FIELD DETAIL START =========== --> <A NAME="field_detail"><!-- --></A> <TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TD COLSPAN=1><FONT SIZE="+2"><B>Field Detail</B></FONT></TD> </TR> </TABLE> <A NAME="__msh_oldSetFullYear"><!-- --></A> <H3>__msh_oldSetFullYear</H3> <PRE>Object <B>__msh_oldSetFullYear</B></PRE> <UL> </UL> <HR> <!-- ============ FIELD DETAIL END =========== --> <!-- ========= CONSTRUCTOR DETAIL START ======== --> <!-- Constructor return value(s) --> <!-- End constructor return value(s) --> <!-- ADDITIONAL ATTRIBUTES --> <HR/> <!-- END ADDITIONAL ATTRIBUTES --> <!-- ========= CONSTRUCTOR DETAIL END ======== --> <!-- ============ METHOD DETAIL START ========== --> <A NAME="method_detail"><!-- --></A> <TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TD COLSPAN=1><FONT SIZE="+2"> <B>Method Detail</B></FONT> </TD> </TR> </TABLE> <!-- One single method detail entry --> <A NAME="compareDatesOnly"><!-- --></A> <H3>compareDatesOnly</H3> <PRE>Object <B>compareDatesOnly</B>(date1,date2)</PRE> <UL>This function compares only years, months and days of two date objects.</UL> <!-- METHOD PARAMETERS START --> <UL> <B>Parameters:</B> <UL><CODE>date1</CODE> - [Date] first date to compare </UL> <UL><CODE>date1</CODE> - [Date] second date to compare </UL> </UL> <!-- METHOD PARAMETERS END --> <UL> <B>Returns:</B> <UL> [int] -1 if date1>date2, 1 if date2>date1 or 0 if they are equal </UL> </UL> <!-- ADDITIONAL ATTRIBUTES START --> <!-- ADDITIONAL ATTRIBUTES END --> <HR> <A NAME="dateEqualsTo"><!-- --></A> <H3>dateEqualsTo</H3> <PRE>Object <B>dateEqualsTo</B>(date)</PRE> <UL>Checks dates equality. Ignores time.</UL> <!-- METHOD PARAMETERS START --> <!-- METHOD PARAMETERS END --> <!-- ADDITIONAL ATTRIBUTES START --> <!-- ADDITIONAL ATTRIBUTES END --> <HR> <A NAME="equalsTo"><!-- --></A> <H3>equalsTo</H3> <PRE>Object <B>equalsTo</B>(date)</PRE> <UL>Checks dates equality. Checks time too.</UL> <!-- METHOD PARAMETERS START --> <!-- METHOD PARAMETERS END --> <!-- ADDITIONAL ATTRIBUTES START --> <!-- ADDITIONAL ATTRIBUTES END --> <HR> <A NAME="getDayOfYear"><!-- --></A> <H3>getDayOfYear</H3> <PRE>Object <B>getDayOfYear</B>()</PRE> <UL>Returns the number of the current day in the current year.</UL> <!-- METHOD PARAMETERS START --> <!-- METHOD PARAMETERS END --> <!-- ADDITIONAL ATTRIBUTES START --> <!-- ADDITIONAL ATTRIBUTES END --> <HR> <A NAME="getMonthDays"><!-- --></A> <H3>getMonthDays</H3> <PRE>Object <B>getMonthDays</B>(month)</PRE> <UL>Returns the number of days in the month. The \em month parameter is optional; if not passed, the current month of \b this Date object is assumed.</UL> <!-- METHOD PARAMETERS START --> <UL> <B>Parameters:</B> <UL><CODE>month</CODE> - [int, optional] the month number, 0 for January. </UL> </UL> <!-- METHOD PARAMETERS END --> <!-- ADDITIONAL ATTRIBUTES START --> <!-- ADDITIONAL ATTRIBUTES END --> <HR> <A NAME="getWeekNumber"><!-- --></A> <H3>getWeekNumber</H3> <PRE>Object <B>getWeekNumber</B>()</PRE> <UL>Returns the number of the week in year, as defined in ISO 8601.</UL> <!-- METHOD PARAMETERS START --> <!-- METHOD PARAMETERS END --> <!-- ADDITIONAL ATTRIBUTES START --> <!-- ADDITIONAL ATTRIBUTES END --> <HR> <A NAME="print"><!-- --></A> <H3>print</H3> <PRE>Object <B>print</B>(str)</PRE> <UL>Prints the date in a string according to the given format. The format (\b str) may contain the following specialties: - %%a - Abbreviated weekday name - %%A - Full weekday name - %%b - Abbreviated month name - %%B - Full month name - %%C - Century number - %%d - The day of the month (00 .. 31) - %%e - The day of the month (0 .. 31) - %%H - Hour (00 .. 23) - %%I - Hour (01 .. 12) - %%j - The day of the year (000 .. 366) - %%k - Hour (0 .. 23) - %%l - Hour (1 .. 12) - %%m - Month (01 .. 12) - %%M - Minute (00 .. 59) - %%n - A newline character - %%p - "PM" or "AM" - %%P - "pm" or "am" - %%S - Second (00 .. 59) - %%s - Number of seconds since Epoch - %%t - A tab character - %%W - The week number (as per ISO 8601) - %%u - The day of week (1 .. 7, 1 = Monday) - %%w - The day of week (0 .. 6, 0 = Sunday) - %%y - Year without the century (00 .. 99) - %%Y - Year including the century (ex. 1979) - %%% - A literal %% character They are almost the same as for the POSIX strftime function.</UL> <!-- METHOD PARAMETERS START --> <UL> <B>Parameters:</B> <UL><CODE>str</CODE> - [string] the format to print date in. </UL> </UL> <!-- METHOD PARAMETERS END --> <!-- ADDITIONAL ATTRIBUTES START --> <!-- ADDITIONAL ATTRIBUTES END --> <HR> <A NAME="setDateOnly"><!-- --></A> <H3>setDateOnly</H3> <PRE>void <B>setDateOnly</B>(date)</PRE> <UL>Set only the year, month, date parts (keep existing time)</UL> <!-- METHOD PARAMETERS START --> <!-- METHOD PARAMETERS END --> <!-- ADDITIONAL ATTRIBUTES START --> <!-- ADDITIONAL ATTRIBUTES END --> <HR> <A NAME="setFullYear"><!-- --></A> <H3>setFullYear</H3> <PRE>void <B>setFullYear</B>(y)</PRE> <UL>This function replaces the original Date.setFullYear() with a "safer" function which makes sure that the month or date aren't modified (unless in the exceptional case where the date is February 29 but the new year doesn't contain it).</UL> <!-- METHOD PARAMETERS START --> <UL> <B>Parameters:</B> <UL><CODE>y</CODE> - [int] the new year to move this date to </UL> </UL> <!-- METHOD PARAMETERS END --> <!-- ADDITIONAL ATTRIBUTES START --> <!-- ADDITIONAL ATTRIBUTES END --> <HR> <A NAME="!s!parseDate"><!-- --></A> <H3>parseDate</H3> <PRE><static> Object <B>parseDate</B>(str, format)</PRE> <UL>Parses a date from a string in the specified format. This function requires strict following of the string to the format template, and any difference causes failure to be returned. Also function refuses to parse formats which containing number rules that have not fixed length and are not separated from the next number rule by any character string, as this requires complication of algorythm and still sometimes is impossible to parse.</UL> <!-- METHOD PARAMETERS START --> <UL> <B>Parameters:</B> <UL><CODE>str</CODE> - [string] the date as a string </UL> <UL><CODE>format</CODE> - [string] the format to try to parse the date in </UL> </UL> <!-- METHOD PARAMETERS END --> <UL> <B>Returns:</B> <UL> [Date] a date object containing the parsed date or \b null if for some reason the date couldn't be parsed. </UL> </UL> <!-- ADDITIONAL ATTRIBUTES START --> <!-- ADDITIONAL ATTRIBUTES END --> <HR> <!-- ============ METHOD DETAIL END ========== --> <!-- ========= END OF CLASS DATA ========= --> <!-- ========== START OF NAVBAR ========== --> <A NAME="navbar_bottom"><!-- --></A> <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0"> <TR> <TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A NAME="navbar_bottom_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> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">File</FONT> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><b>Tree</b></FONT></A> </TD> <!--TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"--> <!--A HREF="deprecated-list.html"--><!--FONT CLASS="NavBarFont1">Deprecated</FONT--><!--/A--><!-- </TD--> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR> </TABLE> </TD> <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM> <B>Zapatec Calendar</B> </EM> </TD </TR> <TR> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <B>PREV CLASS</B><!-- NEXT CLASS --> <A HREF="Zapatec/Calendar.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> <A HREF="" TARGET="_top"><B>NO FRAMES</B></A> <SCRIPT> <!-- if(window==top) { document.writeln('<A HREF="allclasses-noframe.html" TARGET=""><B>All Classes</B></A>'); } //--> </SCRIPT> <NOSCRIPT> <A HREF="allclasses-noframe.html" TARGET=""><B>All Classes</B></A> </NOSCRIPT> </FONT></TD> </TR> <TR> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD> </TR> </TABLE> <!-- =========== END OF NAVBAR =========== --> <HR> <FONT SIZE="-1"> </FONT> <div class="jsdoc_ctime">Documentation generated by <a href="http://jsdoc.sourceforge.net/" target="_parent">JSDoc</a> on Thu Aug 16 12:18:51 2007</div> </BODY> </HTML>