Information Technology Reference
In-Depth Information
id : the object id to search for
- SMSManager.sendTextMessage(String destinationAddress, String
scAddress, String text, PendingIntent sentIntent, PendingIntent
deliveryIntent) :
sends a text-based SMS message
destinationAddress : the address to send the message to
scAddress : the service center address; pass null to use the default
text : the body of the message to send
sentIntent : a broadcast message to be generated by the system when the
message has been sent; pass null if not required
deliveryIntent : a broadcast message for the message delivery; pass null
if not required
2.4 Android.jar: Where Android Lives
The Android middleware consists of predefined Java classes and a set of native
libraries. To be able to compile Android apps that make use of this API on a
desktop PC, the Java classes of the Android API must be present. Therefore, the
Android SDK provides these classes in a file called android.jar in its platforms
directory. There is one such file for every version of the OS. We recommend
using the appropriate version of the JAR file since new APIs are added from
time to time and old, deprecated ones are removed. The minimum compatible
OS version specified in the application's manifest file is usually a good pick.
However, note that these JAR files can only be used to create a somewhat
complete callgraph and points-to set in the user code, but they cannot be used
to actually run the application. This is because for many methods they only
contain stubs and no actual implementations. Stubbed methods just throw a
NotImplementedException . Obtaining a full android.jar file from a real phone
is possible, but not trivial, as the Android API is stored in a precompiled and
optimized file format. In most cases, such complete JAR files are not needed
anyway.
2.5 Useful Tools
The Android SDK provides a number of tools that support a developer during the
developement of an Android application. For instance, debugging or running on
an emulator is essential during the developement phase. Therefore, we will briefly
introduce the two most important tools: Logcat and the Android emulator.
Logcat. Android's logging system provides a mechanism for collecting different
kinds of log messages from various applications and system components. These
logs can be easily viewed and filtered using the logcat tool which is built on
top of Android's debug bridge adb . Logcat can directly be launched from the
command line with adb logcat . It supports various settings for filtering and
Search WWH ::




Custom Search