The androidinternaltelephony Package

This package contains the classes and interfaces PhoneApp uses to provide services to other applications that want to start phone calls, and classes that define an API to the RIL.

PhoneApp, like all parts of Android, is theoretically replaceable. If your application needs to modify the classes used by PhoneApp, your application will probably have to replace or modify PhoneApp, and should provide the same services to other applications, using the classes in this package.

The description of these classes should help you understand how Android interfaces to a mobile radio, and the capabilities that are exposed—and not exposed—by PhoneApp to other applications. This is a large and complex package, and a complete understanding will require reading the Android source code. These descriptions will help you find where to start for your purposes:

ATParseEx

Extends RuntimeException and is thrown by methods of the ATResponseParser class. ATResponseParser

This class parses part of the AT command syntax used to communicate with the mobile radio hardware in a mobile handset. This is, in fact, a command syntax very much like the AT command syntax used by modems, a standard described in the 3GPP document number TS 27.007 and related specifications. This protocol for controlling mobile radios is widely used.

Call

This class is an abstract base class. Other classes use it as a basis for objects that represent phone calls and the state of those calls. CallerInfo

This class holds information about the party that originated an incoming call. This class starts with caller ID information from the mobile network interface and looks up other information about a caller in the database of contacts.

CallerInfoAsyncQuery

This class enables asynchronous database queries for information that could be found about a caller based on the caller ID information. CallStateException

The class extends Exception and is thrown by methods that maintain call state in cases where state is inconsistent.

Connection

This class is an abstract base class used by other classes, and is a basis for objects that represent connections on the mobile network and the state of these connections. Connection objects can be associated with a Call object, but they can also exist independently. The data in a Connection object can be especially useful in diagnosing the reason a call failed.

DefaultPhoneNotifier

This class implements the PhoneNotifier interface in order to receive notifications from a Phone object. It then uses the Android service system to communicate state to Activity instances that have registered to receive those notifications. See the Handler and Mailbox classes for information on how to receive notifications.

IPhoneStateListener

This interface defines the signatures of methods an application implements to receive notification of call state change, and changes to forwarding and message-waiting states. IPhoneSubInfo

This interface is used to obtain subscriber information.

ITelephony

This interface defines the inter-process interface used in TelephonyManager to enable applications to communicate with PhoneApp. ITelephonyRegistry

This interface is the callback interface from the RIL daemon.

MmiCode

This interface defines callbacks related to "MMI codes." These are special numbers a user can dial and key sequences that a user can enter during a call to access, control, and administer supplementary services, such as call waiting, call hold, etc. MMI codes and related functionality are described in the 3GPP document number TS 22.030. Phone

This interface includes callbacks and methods for accessing the state of a mobile phone.

PhoneBase

This class is an abstract base class that implements the Phone interface. PhoneFactory

This class contains methods used to create instances of the GSMPhone class, a subclass of the Phone class.

PhoneNotifier

This interface specifies the API a telephony implementation uses to notify a phone state listener of state changes. PhoneStateIntentReceiver

This class handles Intent objects that have intent types specified in the TelephonyIntents class. This class enables Android applications to use the Intents system to obtain phone state information.

PhoneSubInfo

This class contains methods for obtaining information about a mobile service subscriber, such as the unique identifying number for the handset (IMEI), the unique identifying number for the subscriber (IMSI), the serial number of the SIM card, etc. SimCard

This interface defines the API for accessing the SIM card.

TelephonyIntents

This class defines constants for broadcast intents that have similar functionality to the TelephonyManager API. TelephonyProperties

This class defines the constants used with the SystemProperties class for setting and getting telephony-related properties.

These classes are not documented in the Android SDK documentation, but the descriptions here should give you some understanding of the source code for these classes.

0 0

Post a comment