Translated from:Http://developer.android.com/guide/topics/connectivity/sip.html
Android provides APIs that support the Session Initiation Protocol (SIP. This allows you to add the SIP-based Internet phone function to your application.Program. Android contains a complete SIP protocol stack and integrates the call management service, so that applications can easily establish inbound and outbound connections, you do not need to manage sessions, communication at the transport layer, audio records, and callbacks.
Requirements and restrictions
The following are requirements for developing sip applications:
1. You must have a mobile device running android2.3 or later;
2. Sip runs on wireless data connections, so your device must have a data connection (such as mobile data service or Wi-Fi ). This means that you cannot test on AVD-you can only test on physical devices.
3. Each application communication session participant must have a sip account. There are many different SIP providers that provide sip accounts.
SIP APIs and interfaces
The following is an overview of the classes and an interface (sipregistrationlistener) contained in the android sip API:
Class/interface |
Introduction |
Sipaudiocall
|
Process SIP-based Internet audio calls. |
Sipaudiocall. Listener
|
Listen for SIP call-related events, such as when a call is connected ("On ringing") or called out ("On calling. |
Siperrorcode
|
Defines errors returned during a SIP OperationCode. |
Sipmanager
|
Provides APIs for SIP tasks, such as initiating a sip connection and providing access to related sip services. |
Sipprofile
|
Define the SIP configuration, including the SIP account, domain name, and server information. |
Sipprofile. Builder
|
Create a helper class for a sipprofile object. |
Sipsession
|
Indicates a sip session associated with an independent transaction in the SIP dialog box or no dialog box. |
Sipsession. Listener
|
Listen for SIP session-related events, such as registration sessions ("On registering") or outgoing calls ("On calling. |
Sipsession. State
|
Defines the status of a sip session, such as "registering", "outgoing call", and "in call" |
Sipregistrationlistener
|
Interface for listening to sip registration events. |