You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tasks/com/todoroo/andlib/utility/DateUtilities.html

613 lines
22 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.6.0_26) on Thu Dec 22 20:39:06 PST 2011 -->
<TITLE>
DateUtilities
</TITLE>
<META NAME="date" CONTENT="2011-12-22">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
<SCRIPT type="text/javascript">
function windowTitle()
{
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="DateUtilities";
}
}
</SCRIPT>
<NOSCRIPT>
</NOSCRIPT>
</HEAD>
<BODY BGCOLOR="white" onload="windowTitle();">
<HR>
<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<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/DateUtilities.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>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.SerializedPut.html" title="interface in com.todoroo.andlib.utility"><B>PREV CLASS</B></A>&nbsp;
&nbsp;<A HREF="../../../../com/todoroo/andlib/utility/DialogUtilities.html" title="class in com.todoroo.andlib.utility"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../index.html?com/todoroo/andlib/utility/DateUtilities.html" target="_top"><B>FRAMES</B></A> &nbsp;
&nbsp;<A HREF="DateUtilities.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
&nbsp;<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">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;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->
<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
com.todoroo.andlib.utility</FONT>
<BR>
Class DateUtilities</H2>
<PRE>
java.lang.Object
<IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>com.todoroo.andlib.utility.DateUtilities</B>
</PRE>
<HR>
<DL>
<DT><PRE>public class <B>DateUtilities</B><DT>extends java.lang.Object</DL>
</PRE>
<P>
<HR>
<P>
<!-- =========== FIELD SUMMARY =========== -->
<A NAME="field_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Field Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;long</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#ONE_DAY">ONE_DAY</A></B></CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Represents a single day</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;long</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#ONE_HOUR">ONE_HOUR</A></B></CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Represents a single hour</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;long</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#ONE_MINUTE">ONE_MINUTE</A></B></CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Represents a single minute</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;long</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#ONE_WEEK">ONE_WEEK</A></B></CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Represents a single week</TD>
</TR>
</TABLE>
&nbsp;
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#DateUtilities()">DateUtilities</A></B>()</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
</TABLE>
&nbsp;
<!-- ========== METHOD SUMMARY =========== -->
<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Method Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;long</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#addCalendarMonthsToUnixtime(long, int)">addCalendarMonthsToUnixtime</A></B>(long&nbsp;time,
int&nbsp;interval)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Add the specified amount of months to the given time.<br/>
The day of month will stay the same.<br/></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;long</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#dateToUnixtime(java.util.Date)">dateToUnixtime</A></B>(java.util.Date&nbsp;date)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convert date into unixtime</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#getDateString(android.content.Context, java.util.Date)">getDateString</A></B>(android.content.Context&nbsp;context,
java.util.Date&nbsp;date)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#getDateStringWithTime(android.content.Context, java.util.Date)">getDateStringWithTime</A></B>(android.content.Context&nbsp;context,
java.util.Date&nbsp;date)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#getDateStringWithTimeAndWeekday(android.content.Context, java.util.Date)">getDateStringWithTimeAndWeekday</A></B>(android.content.Context&nbsp;context,
java.util.Date&nbsp;date)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#getDateStringWithWeekday(android.content.Context, java.util.Date)">getDateStringWithWeekday</A></B>(android.content.Context&nbsp;context,
java.util.Date&nbsp;date)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#getRelativeDay(android.content.Context, long)">getRelativeDay</A></B>(android.content.Context&nbsp;context,
long&nbsp;date)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#getTimeString(android.content.Context, java.util.Date)">getTimeString</A></B>(android.content.Context&nbsp;context,
java.util.Date&nbsp;date)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#getWeekday(java.util.Date)">getWeekday</A></B>(java.util.Date&nbsp;date)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;boolean</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#is24HourFormat(android.content.Context)">is24HourFormat</A></B>(android.content.Context&nbsp;context)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;long</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#now()">now</A></B>()</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns unixtime for current time</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;long</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#oneMonthFromNow()">oneMonthFromNow</A></B>()</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns unixtime one month from now</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.util.Date</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/DateUtilities.html#unixtimeToDate(long)">unixtimeToDate</A></B>(long&nbsp;millis)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convert unixtime into date</TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Methods inherited from class java.lang.Object</B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
</TR>
</TABLE>
&nbsp;
<P>
<!-- ============ FIELD DETAIL =========== -->
<A NAME="field_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Field Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="ONE_HOUR"><!-- --></A><H3>
ONE_HOUR</H3>
<PRE>
public static long <B>ONE_HOUR</B></PRE>
<DL>
<DD>Represents a single hour
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="ONE_DAY"><!-- --></A><H3>
ONE_DAY</H3>
<PRE>
public static long <B>ONE_DAY</B></PRE>
<DL>
<DD>Represents a single day
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="ONE_WEEK"><!-- --></A><H3>
ONE_WEEK</H3>
<PRE>
public static long <B>ONE_WEEK</B></PRE>
<DL>
<DD>Represents a single week
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="ONE_MINUTE"><!-- --></A><H3>
ONE_MINUTE</H3>
<PRE>
public static long <B>ONE_MINUTE</B></PRE>
<DL>
<DD>Represents a single minute
<P>
<DL>
</DL>
</DL>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="DateUtilities()"><!-- --></A><H3>
DateUtilities</H3>
<PRE>
public <B>DateUtilities</B>()</PRE>
<DL>
</DL>
<!-- ============ METHOD DETAIL ========== -->
<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Method Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="unixtimeToDate(long)"><!-- --></A><H3>
unixtimeToDate</H3>
<PRE>
public static final java.util.Date <B>unixtimeToDate</B>(long&nbsp;millis)</PRE>
<DL>
<DD>Convert unixtime into date
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="dateToUnixtime(java.util.Date)"><!-- --></A><H3>
dateToUnixtime</H3>
<PRE>
public static final long <B>dateToUnixtime</B>(java.util.Date&nbsp;date)</PRE>
<DL>
<DD>Convert date into unixtime
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="addCalendarMonthsToUnixtime(long, int)"><!-- --></A><H3>
addCalendarMonthsToUnixtime</H3>
<PRE>
public static final long <B>addCalendarMonthsToUnixtime</B>(long&nbsp;time,
int&nbsp;interval)</PRE>
<DL>
<DD>Add the specified amount of months to the given time.<br/>
The day of month will stay the same.<br/>
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>time</CODE> - the base-time (in milliseconds) to which the amount of months is added<DD><CODE>interval</CODE> - the amount of months to be added
<DT><B>Returns:</B><DD>the calculated time in milliseconds</DL>
</DD>
</DL>
<HR>
<A NAME="now()"><!-- --></A><H3>
now</H3>
<PRE>
public static final long <B>now</B>()</PRE>
<DL>
<DD>Returns unixtime for current time
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="oneMonthFromNow()"><!-- --></A><H3>
oneMonthFromNow</H3>
<PRE>
public static final long <B>oneMonthFromNow</B>()</PRE>
<DL>
<DD>Returns unixtime one month from now
<P>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="is24HourFormat(android.content.Context)"><!-- --></A><H3>
is24HourFormat</H3>
<PRE>
public static boolean <B>is24HourFormat</B>(android.content.Context&nbsp;context)</PRE>
<DL>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="getTimeString(android.content.Context, java.util.Date)"><!-- --></A><H3>
getTimeString</H3>
<PRE>
public static java.lang.String <B>getTimeString</B>(android.content.Context&nbsp;context,
java.util.Date&nbsp;date)</PRE>
<DL>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>context</CODE> - android context<DD><CODE>date</CODE> - time to format
<DT><B>Returns:</B><DD>time, with hours and minutes</DL>
</DD>
</DL>
<HR>
<A NAME="getDateString(android.content.Context, java.util.Date)"><!-- --></A><H3>
getDateString</H3>
<PRE>
public static java.lang.String <B>getDateString</B>(android.content.Context&nbsp;context,
java.util.Date&nbsp;date)</PRE>
<DL>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>context</CODE> - android context<DD><CODE>date</CODE> - date to format
<DT><B>Returns:</B><DD>date, with month, day, and year</DL>
</DD>
</DL>
<HR>
<A NAME="getDateStringWithWeekday(android.content.Context, java.util.Date)"><!-- --></A><H3>
getDateStringWithWeekday</H3>
<PRE>
public static java.lang.String <B>getDateStringWithWeekday</B>(android.content.Context&nbsp;context,
java.util.Date&nbsp;date)</PRE>
<DL>
<DD><DL>
<DT><B>Returns:</B><DD>date format as getDateFormat with weekday</DL>
</DD>
</DL>
<HR>
<A NAME="getWeekday(java.util.Date)"><!-- --></A><H3>
getWeekday</H3>
<PRE>
public static java.lang.String <B>getWeekday</B>(java.util.Date&nbsp;date)</PRE>
<DL>
<DD><DL>
<DT><B>Returns:</B><DD>weekday</DL>
</DD>
</DL>
<HR>
<A NAME="getDateStringWithTimeAndWeekday(android.content.Context, java.util.Date)"><!-- --></A><H3>
getDateStringWithTimeAndWeekday</H3>
<PRE>
public static java.lang.String <B>getDateStringWithTimeAndWeekday</B>(android.content.Context&nbsp;context,
java.util.Date&nbsp;date)</PRE>
<DL>
<DD><DL>
<DT><B>Returns:</B><DD>date format as getDateFormat with weekday</DL>
</DD>
</DL>
<HR>
<A NAME="getDateStringWithTime(android.content.Context, java.util.Date)"><!-- --></A><H3>
getDateStringWithTime</H3>
<PRE>
public static java.lang.String <B>getDateStringWithTime</B>(android.content.Context&nbsp;context,
java.util.Date&nbsp;date)</PRE>
<DL>
<DD><DL>
<DT><B>Returns:</B><DD>date with time at the end</DL>
</DD>
</DL>
<HR>
<A NAME="getRelativeDay(android.content.Context, long)"><!-- --></A><H3>
getRelativeDay</H3>
<PRE>
public static java.lang.String <B>getRelativeDay</B>(android.content.Context&nbsp;context,
long&nbsp;date)</PRE>
<DL>
<DD><DL>
<DT><B>Returns:</B><DD>yesterday, today, tomorrow, or null</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<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/DateUtilities.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>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.SerializedPut.html" title="interface in com.todoroo.andlib.utility"><B>PREV CLASS</B></A>&nbsp;
&nbsp;<A HREF="../../../../com/todoroo/andlib/utility/DialogUtilities.html" title="class in com.todoroo.andlib.utility"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../index.html?com/todoroo/andlib/utility/DateUtilities.html" target="_top"><B>FRAMES</B></A> &nbsp;
&nbsp;<A HREF="DateUtilities.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
&nbsp;<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">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;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<HR>
</BODY>
</HTML>