mirror of https://github.com/tasks/tasks
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.
1043 lines
41 KiB
HTML
1043 lines
41 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>
|
|
AndroidUtilities
|
|
</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="AndroidUtilities";
|
|
}
|
|
}
|
|
</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> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/AndroidUtilities.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-files/index-1.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>
|
|
</EM>
|
|
</TD>
|
|
</TR>
|
|
|
|
<TR>
|
|
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
|
PREV CLASS
|
|
<A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.SerializedPut.html" title="interface 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/AndroidUtilities.html" target="_top"><B>FRAMES</B></A>
|
|
<A HREF="AndroidUtilities.html" target="_top"><B>NO FRAMES</B></A>
|
|
<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: <A HREF="#nested_class_summary">NESTED</A> | <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>
|
|
<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 AndroidUtilities</H2>
|
|
<PRE>
|
|
java.lang.Object
|
|
<IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>com.todoroo.andlib.utility.AndroidUtilities</B>
|
|
</PRE>
|
|
<HR>
|
|
<DL>
|
|
<DT><PRE>public class <B>AndroidUtilities</B><DT>extends java.lang.Object</DL>
|
|
</PRE>
|
|
|
|
<P>
|
|
Android Utility Classes
|
|
<P>
|
|
|
|
<P>
|
|
<DL>
|
|
<DT><B>Author:</B></DT>
|
|
<DD>Tim Su <tim@todoroo.com></DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<P>
|
|
<!-- ======== NESTED CLASS SUMMARY ======== -->
|
|
|
|
<A NAME="nested_class_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>Nested Class Summary</B></FONT></TH>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static interface</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.SerializedPut.html" title="interface in com.todoroo.andlib.utility">AndroidUtilities.SerializedPut</A><<A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.SerializedPut.html" title="type parameter in AndroidUtilities.SerializedPut">T</A>></B></CODE>
|
|
|
|
<BR>
|
|
</TD>
|
|
</TR>
|
|
</TABLE>
|
|
<!-- =========== 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 java.lang.String</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#SEPARATOR_ESCAPE">SEPARATOR_ESCAPE</A></B></CODE>
|
|
|
|
<BR>
|
|
</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static java.lang.String</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#SERIALIZATION_SEPARATOR">SERIALIZATION_SEPARATOR</A></B></CODE>
|
|
|
|
<BR>
|
|
</TD>
|
|
</TR>
|
|
</TABLE>
|
|
|
|
<!-- ======== 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/AndroidUtilities.html#AndroidUtilities()">AndroidUtilities</A></B>()</CODE>
|
|
|
|
<BR>
|
|
</TD>
|
|
</TR>
|
|
</TABLE>
|
|
|
|
<!-- ========== 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 <A HREF="../../../../com/todoroo/andlib/data/Property.html" title="class in com.todoroo.andlib.data">Property</A><?>[]</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#addToArray(com.todoroo.andlib.data.Property[], com.todoroo.andlib.data.Property...)">addToArray</A></B>(<A HREF="../../../../com/todoroo/andlib/data/Property.html" title="class in com.todoroo.andlib.data">Property</A><?>[] list,
|
|
<A HREF="../../../../com/todoroo/andlib/data/Property.html" title="class in com.todoroo.andlib.data">Property</A><?>... newItems)</CODE>
|
|
|
|
<BR>
|
|
Join items to a list</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static android.os.Bundle</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#bundleFromSerializedString(java.lang.String)">bundleFromSerializedString</A></B>(java.lang.String string)</CODE>
|
|
|
|
<BR>
|
|
Turn <CODE>Bundle</CODE> into a string</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static java.lang.String</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#bundleToSerializedString(android.os.Bundle)">bundleToSerializedString</A></B>(android.os.Bundle source)</CODE>
|
|
|
|
<BR>
|
|
Serializes a <CODE>Bundle</CODE> into a string</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static java.lang.Object</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#callApiMethod(int, java.lang.Object, java.lang.String, java.lang.Class[], java.lang.Object...)">callApiMethod</A></B>(int minSdk,
|
|
java.lang.Object receiver,
|
|
java.lang.String methodName,
|
|
java.lang.Class<?>[] params,
|
|
java.lang.Object... args)</CODE>
|
|
|
|
<BR>
|
|
Call a method via reflection if API level is at least minSdk</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static java.lang.String</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#capitalize(java.lang.String)">capitalize</A></B>(java.lang.String string)</CODE>
|
|
|
|
<BR>
|
|
Capitalize the first character</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static
|
|
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
|
|
<TR ALIGN="right" VALIGN="">
|
|
<TD NOWRAP><FONT SIZE="-1">
|
|
<CODE><TYPE> TYPE[]</CODE></FONT></TD>
|
|
</TR>
|
|
</TABLE>
|
|
</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#concat(TYPE[], TYPE[], TYPE...)">concat</A></B>(TYPE[] dest,
|
|
TYPE[] source,
|
|
TYPE... additional)</CODE>
|
|
|
|
<BR>
|
|
Concatenate additional stuff to the end of the array</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static android.content.ContentValues</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#contentValuesFromSerializedString(java.lang.String)">contentValuesFromSerializedString</A></B>(java.lang.String string)</CODE>
|
|
|
|
<BR>
|
|
Turn ContentValues into a string</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static android.content.ContentValues</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#contentValuesFromString(java.lang.String)">contentValuesFromString</A></B>(java.lang.String string)</CODE>
|
|
|
|
<BR>
|
|
Turn ContentValues into a string</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static java.lang.String</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#contentValuesToSerializedString(android.content.ContentValues)">contentValuesToSerializedString</A></B>(android.content.ContentValues source)</CODE>
|
|
|
|
<BR>
|
|
Serializes a content value into a string</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static java.lang.String[][]</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#contentValuesToStringArrays(android.content.ContentValues)">contentValuesToStringArrays</A></B>(android.content.ContentValues source)</CODE>
|
|
|
|
<BR>
|
|
Rips apart a content value into two string arrays, keys and value</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static void</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#copyDatabases(android.content.Context, java.lang.String)">copyDatabases</A></B>(android.content.Context context,
|
|
java.lang.String folder)</CODE>
|
|
|
|
<BR>
|
|
Copy databases to a given folder.</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static void</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#copyFile(java.io.File, java.io.File)">copyFile</A></B>(java.io.File in,
|
|
java.io.File out)</CODE>
|
|
|
|
<BR>
|
|
Copy a file from one place to another</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static void</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#copyStream(java.io.InputStream, java.io.OutputStream)">copyStream</A></B>(java.io.InputStream source,
|
|
java.io.OutputStream dest)</CODE>
|
|
|
|
<BR>
|
|
Copy stream from source to destination</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static boolean</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#equals(java.lang.Object, java.lang.Object)">equals</A></B>(java.lang.Object a,
|
|
java.lang.Object b)</CODE>
|
|
|
|
<BR>
|
|
Returns true if a and b or null or a.equals(b)</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static android.graphics.Bitmap</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#fetchImage(java.net.URL)">fetchImage</A></B>(java.net.URL url)</CODE>
|
|
|
|
<BR>
|
|
Fetch the image specified by the given url</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static
|
|
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
|
|
<TR ALIGN="right" VALIGN="">
|
|
<TD NOWRAP><FONT SIZE="-1">
|
|
<CODE><KEY,VALUE>
|
|
<BR>
|
|
KEY</CODE></FONT></TD>
|
|
</TR>
|
|
</TABLE>
|
|
</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#findKeyInMap(java.util.Map, VALUE)">findKeyInMap</A></B>(java.util.Map<KEY,VALUE> map,
|
|
VALUE value)</CODE>
|
|
|
|
<BR>
|
|
Search for the given value in the map, returning key if found</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static
|
|
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
|
|
<TR ALIGN="right" VALIGN="">
|
|
<TD NOWRAP><FONT SIZE="-1">
|
|
<CODE><TYPE> TYPE</CODE></FONT></TD>
|
|
</TR>
|
|
</TABLE>
|
|
</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#findViewByType(android.view.View, java.lang.Class)">findViewByType</A></B>(android.view.View view,
|
|
java.lang.Class<TYPE> type)</CODE>
|
|
|
|
<BR>
|
|
Find a child view of a certain type</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static int</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#getSdkVersion()">getSdkVersion</A></B>()</CODE>
|
|
|
|
<BR>
|
|
</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static java.lang.String</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#getSignature(android.content.Context, java.lang.String)">getSignature</A></B>(android.content.Context context,
|
|
java.lang.String packageName)</CODE>
|
|
|
|
<BR>
|
|
Gets application signature</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static
|
|
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
|
|
<TR ALIGN="right" VALIGN="">
|
|
<TD NOWRAP><FONT SIZE="-1">
|
|
<CODE><TYPE> int</CODE></FONT></TD>
|
|
</TR>
|
|
</TABLE>
|
|
</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#indexOf(TYPE[], TYPE)">indexOf</A></B>(TYPE[] array,
|
|
TYPE value)</CODE>
|
|
|
|
<BR>
|
|
Return index of value in array</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static boolean</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#isConnected(android.content.Context)">isConnected</A></B>(android.content.Context context)</CODE>
|
|
|
|
<BR>
|
|
</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static java.lang.String</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#md5(java.lang.String)">md5</A></B>(java.lang.String input)</CODE>
|
|
|
|
<BR>
|
|
Performs an md5 hash on the input string</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static void</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#putInto(android.content.ContentValues, java.lang.String, java.lang.Object)">putInto</A></B>(android.content.ContentValues target,
|
|
java.lang.String key,
|
|
java.lang.Object value)</CODE>
|
|
|
|
<BR>
|
|
Put an arbitrary object into a <CODE>ContentValues</CODE></TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static java.lang.CharSequence</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#readFile(android.content.Context, int)">readFile</A></B>(android.content.Context activity,
|
|
int id)</CODE>
|
|
|
|
<BR>
|
|
From Android MyTracks project (http://mytracks.googlecode.com/).</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static android.content.Intent</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#remoteIntent(java.lang.String, java.lang.String)">remoteIntent</A></B>(java.lang.String appPackage,
|
|
java.lang.String activityClass)</CODE>
|
|
|
|
<BR>
|
|
Create an intent to a remote activity</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static void</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#sleepDeep(long)">sleepDeep</A></B>(long l)</CODE>
|
|
|
|
<BR>
|
|
Sleep, ignoring interruption.</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static void</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#sortFilesByDateDesc(java.io.File[])">sortFilesByDateDesc</A></B>(java.io.File[] files)</CODE>
|
|
|
|
<BR>
|
|
Sort files by date so the newest file is on top</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static void</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#startExternalIntent(android.content.Context, android.content.Intent, int)">startExternalIntent</A></B>(android.content.Context context,
|
|
android.content.Intent intent,
|
|
int request)</CODE>
|
|
|
|
<BR>
|
|
Start the given intent, handling security exceptions if they arise</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static void</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#startExternalIntentForResult(android.app.Activity, android.content.Intent, int)">startExternalIntentForResult</A></B>(android.app.Activity activity,
|
|
android.content.Intent intent,
|
|
int requestCode)</CODE>
|
|
|
|
<BR>
|
|
Start the given intent, handling security exceptions if they arise</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>static void</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.html#suppressVirtualKeyboard(android.widget.TextView)">suppressVirtualKeyboard</A></B>(android.widget.TextView editor)</CODE>
|
|
|
|
<BR>
|
|
Suppress virtual keyboard until user's first tap</TD>
|
|
</TR>
|
|
</TABLE>
|
|
<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>
|
|
|
|
<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="SEPARATOR_ESCAPE"><!-- --></A><H3>
|
|
SEPARATOR_ESCAPE</H3>
|
|
<PRE>
|
|
public static final java.lang.String <B>SEPARATOR_ESCAPE</B></PRE>
|
|
<DL>
|
|
<DL>
|
|
<DT><B>See Also:</B><DD><A HREF="../../../../constant-values.html#com.todoroo.andlib.utility.AndroidUtilities.SEPARATOR_ESCAPE">Constant Field Values</A></DL>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="SERIALIZATION_SEPARATOR"><!-- --></A><H3>
|
|
SERIALIZATION_SEPARATOR</H3>
|
|
<PRE>
|
|
public static final java.lang.String <B>SERIALIZATION_SEPARATOR</B></PRE>
|
|
<DL>
|
|
<DL>
|
|
<DT><B>See Also:</B><DD><A HREF="../../../../constant-values.html#com.todoroo.andlib.utility.AndroidUtilities.SERIALIZATION_SEPARATOR">Constant Field Values</A></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="AndroidUtilities()"><!-- --></A><H3>
|
|
AndroidUtilities</H3>
|
|
<PRE>
|
|
public <B>AndroidUtilities</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="suppressVirtualKeyboard(android.widget.TextView)"><!-- --></A><H3>
|
|
suppressVirtualKeyboard</H3>
|
|
<PRE>
|
|
public static void <B>suppressVirtualKeyboard</B>(android.widget.TextView editor)</PRE>
|
|
<DL>
|
|
<DD>Suppress virtual keyboard until user's first tap
|
|
<P>
|
|
<DD><DL>
|
|
</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="isConnected(android.content.Context)"><!-- --></A><H3>
|
|
isConnected</H3>
|
|
<PRE>
|
|
public static boolean <B>isConnected</B>(android.content.Context context)</PRE>
|
|
<DL>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>true if we're connected to the internet</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="fetchImage(java.net.URL)"><!-- --></A><H3>
|
|
fetchImage</H3>
|
|
<PRE>
|
|
public static android.graphics.Bitmap <B>fetchImage</B>(java.net.URL url)
|
|
throws java.io.IOException</PRE>
|
|
<DL>
|
|
<DD>Fetch the image specified by the given url
|
|
<P>
|
|
<DD><DL>
|
|
|
|
<DT><B>Throws:</B>
|
|
<DD><CODE>java.io.IOException</CODE></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="startExternalIntent(android.content.Context, android.content.Intent, int)"><!-- --></A><H3>
|
|
startExternalIntent</H3>
|
|
<PRE>
|
|
public static void <B>startExternalIntent</B>(android.content.Context context,
|
|
android.content.Intent intent,
|
|
int request)</PRE>
|
|
<DL>
|
|
<DD>Start the given intent, handling security exceptions if they arise
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>context</CODE> - <DD><CODE>intent</CODE> - <DD><CODE>request</CODE> - request code. if negative, no request.</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="startExternalIntentForResult(android.app.Activity, android.content.Intent, int)"><!-- --></A><H3>
|
|
startExternalIntentForResult</H3>
|
|
<PRE>
|
|
public static void <B>startExternalIntentForResult</B>(android.app.Activity activity,
|
|
android.content.Intent intent,
|
|
int requestCode)</PRE>
|
|
<DL>
|
|
<DD>Start the given intent, handling security exceptions if they arise
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>activity</CODE> - <DD><CODE>intent</CODE> - <DD><CODE>requestCode</CODE> - </DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="putInto(android.content.ContentValues, java.lang.String, java.lang.Object)"><!-- --></A><H3>
|
|
putInto</H3>
|
|
<PRE>
|
|
public static void <B>putInto</B>(android.content.ContentValues target,
|
|
java.lang.String key,
|
|
java.lang.Object value)</PRE>
|
|
<DL>
|
|
<DD>Put an arbitrary object into a <CODE>ContentValues</CODE>
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>target</CODE> - <DD><CODE>key</CODE> - <DD><CODE>value</CODE> - </DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="contentValuesToStringArrays(android.content.ContentValues)"><!-- --></A><H3>
|
|
contentValuesToStringArrays</H3>
|
|
<PRE>
|
|
public static java.lang.String[][] <B>contentValuesToStringArrays</B>(android.content.ContentValues source)</PRE>
|
|
<DL>
|
|
<DD>Rips apart a content value into two string arrays, keys and value
|
|
<P>
|
|
<DD><DL>
|
|
</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="indexOf(java.lang.Object[],java.lang.Object)"><!-- --></A><A NAME="indexOf(TYPE[], TYPE)"><!-- --></A><H3>
|
|
indexOf</H3>
|
|
<PRE>
|
|
public static <TYPE> int <B>indexOf</B>(TYPE[] array,
|
|
TYPE value)</PRE>
|
|
<DL>
|
|
<DD>Return index of value in array
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>array</CODE> - array to search<DD><CODE>value</CODE> - value to look for
|
|
<DT><B>Returns:</B><DD></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="contentValuesToSerializedString(android.content.ContentValues)"><!-- --></A><H3>
|
|
contentValuesToSerializedString</H3>
|
|
<PRE>
|
|
public static java.lang.String <B>contentValuesToSerializedString</B>(android.content.ContentValues source)</PRE>
|
|
<DL>
|
|
<DD>Serializes a content value into a string
|
|
<P>
|
|
<DD><DL>
|
|
</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="bundleToSerializedString(android.os.Bundle)"><!-- --></A><H3>
|
|
bundleToSerializedString</H3>
|
|
<PRE>
|
|
public static java.lang.String <B>bundleToSerializedString</B>(android.os.Bundle source)</PRE>
|
|
<DL>
|
|
<DD>Serializes a <CODE>Bundle</CODE> into a string
|
|
<P>
|
|
<DD><DL>
|
|
</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="contentValuesFromSerializedString(java.lang.String)"><!-- --></A><H3>
|
|
contentValuesFromSerializedString</H3>
|
|
<PRE>
|
|
public static android.content.ContentValues <B>contentValuesFromSerializedString</B>(java.lang.String string)</PRE>
|
|
<DL>
|
|
<DD>Turn ContentValues into a string
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>string</CODE> -
|
|
<DT><B>Returns:</B><DD></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="bundleFromSerializedString(java.lang.String)"><!-- --></A><H3>
|
|
bundleFromSerializedString</H3>
|
|
<PRE>
|
|
public static android.os.Bundle <B>bundleFromSerializedString</B>(java.lang.String string)</PRE>
|
|
<DL>
|
|
<DD>Turn <CODE>Bundle</CODE> into a string
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>string</CODE> -
|
|
<DT><B>Returns:</B><DD></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="contentValuesFromString(java.lang.String)"><!-- --></A><H3>
|
|
contentValuesFromString</H3>
|
|
<PRE>
|
|
public static android.content.ContentValues <B>contentValuesFromString</B>(java.lang.String string)</PRE>
|
|
<DL>
|
|
<DD>Turn ContentValues into a string
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>string</CODE> -
|
|
<DT><B>Returns:</B><DD></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="equals(java.lang.Object, java.lang.Object)"><!-- --></A><H3>
|
|
equals</H3>
|
|
<PRE>
|
|
public static boolean <B>equals</B>(java.lang.Object a,
|
|
java.lang.Object b)</PRE>
|
|
<DL>
|
|
<DD>Returns true if a and b or null or a.equals(b)
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>a</CODE> - <DD><CODE>b</CODE> -
|
|
<DT><B>Returns:</B><DD></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="copyFile(java.io.File, java.io.File)"><!-- --></A><H3>
|
|
copyFile</H3>
|
|
<PRE>
|
|
public static void <B>copyFile</B>(java.io.File in,
|
|
java.io.File out)
|
|
throws java.lang.Exception</PRE>
|
|
<DL>
|
|
<DD>Copy a file from one place to another
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>in</CODE> - <DD><CODE>out</CODE> -
|
|
<DT><B>Throws:</B>
|
|
<DD><CODE>java.lang.Exception</CODE></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="copyStream(java.io.InputStream, java.io.OutputStream)"><!-- --></A><H3>
|
|
copyStream</H3>
|
|
<PRE>
|
|
public static void <B>copyStream</B>(java.io.InputStream source,
|
|
java.io.OutputStream dest)
|
|
throws java.io.IOException</PRE>
|
|
<DL>
|
|
<DD>Copy stream from source to destination
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>source</CODE> - <DD><CODE>dest</CODE> -
|
|
<DT><B>Throws:</B>
|
|
<DD><CODE>java.io.IOException</CODE></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="findViewByType(android.view.View, java.lang.Class)"><!-- --></A><H3>
|
|
findViewByType</H3>
|
|
<PRE>
|
|
public static <TYPE> TYPE <B>findViewByType</B>(android.view.View view,
|
|
java.lang.Class<TYPE> type)</PRE>
|
|
<DL>
|
|
<DD>Find a child view of a certain type
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>view</CODE> - <DD><CODE>type</CODE> -
|
|
<DT><B>Returns:</B><DD>first view (by DFS) if found, or null if none</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="getSdkVersion()"><!-- --></A><H3>
|
|
getSdkVersion</H3>
|
|
<PRE>
|
|
public static int <B>getSdkVersion</B>()</PRE>
|
|
<DL>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>Android SDK version as an integer. Works on all versions</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="copyDatabases(android.content.Context, java.lang.String)"><!-- --></A><H3>
|
|
copyDatabases</H3>
|
|
<PRE>
|
|
public static void <B>copyDatabases</B>(android.content.Context context,
|
|
java.lang.String folder)</PRE>
|
|
<DL>
|
|
<DD>Copy databases to a given folder. Useful for debugging
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>folder</CODE> - </DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="sortFilesByDateDesc(java.io.File[])"><!-- --></A><H3>
|
|
sortFilesByDateDesc</H3>
|
|
<PRE>
|
|
public static void <B>sortFilesByDateDesc</B>(java.io.File[] files)</PRE>
|
|
<DL>
|
|
<DD>Sort files by date so the newest file is on top
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>files</CODE> - </DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="findKeyInMap(java.util.Map,java.lang.Object)"><!-- --></A><A NAME="findKeyInMap(java.util.Map, VALUE)"><!-- --></A><H3>
|
|
findKeyInMap</H3>
|
|
<PRE>
|
|
public static <KEY,VALUE> KEY <B>findKeyInMap</B>(java.util.Map<KEY,VALUE> map,
|
|
VALUE value)</PRE>
|
|
<DL>
|
|
<DD>Search for the given value in the map, returning key if found
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>map</CODE> - <DD><CODE>value</CODE> -
|
|
<DT><B>Returns:</B><DD>null if not found, otherwise key</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="sleepDeep(long)"><!-- --></A><H3>
|
|
sleepDeep</H3>
|
|
<PRE>
|
|
public static void <B>sleepDeep</B>(long l)</PRE>
|
|
<DL>
|
|
<DD>Sleep, ignoring interruption. Before using this method, think carefully
|
|
about why you are ignoring interruptions.
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>l</CODE> - </DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="callApiMethod(int, java.lang.Object, java.lang.String, java.lang.Class[], java.lang.Object...)"><!-- --></A><H3>
|
|
callApiMethod</H3>
|
|
<PRE>
|
|
public static java.lang.Object <B>callApiMethod</B>(int minSdk,
|
|
java.lang.Object receiver,
|
|
java.lang.String methodName,
|
|
java.lang.Class<?>[] params,
|
|
java.lang.Object... args)</PRE>
|
|
<DL>
|
|
<DD>Call a method via reflection if API level is at least minSdk
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>minSdk</CODE> - minimum sdk number (i.e. 8)<DD><CODE>receiver</CODE> - object to call method on<DD><CODE>methodName</CODE> - method name to call<DD><CODE>params</CODE> - method parameter types<DD><CODE>args</CODE> - arguments
|
|
<DT><B>Returns:</B><DD>method return value, or null if nothing was called or exception</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="readFile(android.content.Context, int)"><!-- --></A><H3>
|
|
readFile</H3>
|
|
<PRE>
|
|
public static java.lang.CharSequence <B>readFile</B>(android.content.Context activity,
|
|
int id)</PRE>
|
|
<DL>
|
|
<DD>From Android MyTracks project (http://mytracks.googlecode.com/).
|
|
Licensed under the Apache Public License v2
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>activity</CODE> - <DD><CODE>id</CODE> -
|
|
<DT><B>Returns:</B><DD></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="md5(java.lang.String)"><!-- --></A><H3>
|
|
md5</H3>
|
|
<PRE>
|
|
public static java.lang.String <B>md5</B>(java.lang.String input)</PRE>
|
|
<DL>
|
|
<DD>Performs an md5 hash on the input string
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>input</CODE> -
|
|
<DT><B>Returns:</B><DD></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="remoteIntent(java.lang.String, java.lang.String)"><!-- --></A><H3>
|
|
remoteIntent</H3>
|
|
<PRE>
|
|
public static android.content.Intent <B>remoteIntent</B>(java.lang.String appPackage,
|
|
java.lang.String activityClass)</PRE>
|
|
<DL>
|
|
<DD>Create an intent to a remote activity
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>appPackage</CODE> - <DD><CODE>activityClass</CODE> -
|
|
<DT><B>Returns:</B><DD></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="getSignature(android.content.Context, java.lang.String)"><!-- --></A><H3>
|
|
getSignature</H3>
|
|
<PRE>
|
|
public static java.lang.String <B>getSignature</B>(android.content.Context context,
|
|
java.lang.String packageName)</PRE>
|
|
<DL>
|
|
<DD>Gets application signature
|
|
<P>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>application signature, or null if an error was encountered</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="addToArray(com.todoroo.andlib.data.Property[], com.todoroo.andlib.data.Property...)"><!-- --></A><H3>
|
|
addToArray</H3>
|
|
<PRE>
|
|
public static <A HREF="../../../../com/todoroo/andlib/data/Property.html" title="class in com.todoroo.andlib.data">Property</A><?>[] <B>addToArray</B>(<A HREF="../../../../com/todoroo/andlib/data/Property.html" title="class in com.todoroo.andlib.data">Property</A><?>[] list,
|
|
<A HREF="../../../../com/todoroo/andlib/data/Property.html" title="class in com.todoroo.andlib.data">Property</A><?>... newItems)</PRE>
|
|
<DL>
|
|
<DD>Join items to a list
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Type Parameters:</B><DD><CODE>TYPE</CODE> - <DT><B>Parameters:</B><DD><CODE>list</CODE> - <DD><CODE>newList</CODE> - <DD><CODE>newItems</CODE> -
|
|
<DT><B>Returns:</B><DD></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="concat(java.lang.Object[],java.lang.Object[],java.lang.Object[])"><!-- --></A><A NAME="concat(TYPE[], TYPE[], TYPE...)"><!-- --></A><H3>
|
|
concat</H3>
|
|
<PRE>
|
|
public static <TYPE> TYPE[] <B>concat</B>(TYPE[] dest,
|
|
TYPE[] source,
|
|
TYPE... additional)</PRE>
|
|
<DL>
|
|
<DD>Concatenate additional stuff to the end of the array
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>params</CODE> - <DD><CODE>additional</CODE> -
|
|
<DT><B>Returns:</B><DD></DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="capitalize(java.lang.String)"><!-- --></A><H3>
|
|
capitalize</H3>
|
|
<PRE>
|
|
public static java.lang.String <B>capitalize</B>(java.lang.String string)</PRE>
|
|
<DL>
|
|
<DD>Capitalize the first character
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>string</CODE> -
|
|
<DT><B>Returns:</B><DD></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> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/AndroidUtilities.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-files/index-1.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>
|
|
</EM>
|
|
</TD>
|
|
</TR>
|
|
|
|
<TR>
|
|
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
|
PREV CLASS
|
|
<A HREF="../../../../com/todoroo/andlib/utility/AndroidUtilities.SerializedPut.html" title="interface 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/AndroidUtilities.html" target="_top"><B>FRAMES</B></A>
|
|
<A HREF="AndroidUtilities.html" target="_top"><B>NO FRAMES</B></A>
|
|
<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: <A HREF="#nested_class_summary">NESTED</A> | <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>
|
|
<A NAME="skip-navbar_bottom"></A>
|
|
<!-- ======== END OF BOTTOM NAVBAR ======= -->
|
|
|
|
<HR>
|
|
|
|
</BODY>
|
|
</HTML>
|