public class TelecomServiceUtils
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static android.telecom.PhoneAccountHandle |
createPhoneAccountHandle(android.content.Context context,
java.lang.String accountName)
Create a
PhoneAccountHandle for the given parameter. |
static java.lang.String |
getAccountName() |
static void |
registerNewPhoneAccount(android.content.Context context,
java.lang.String accountName)
Create a new
PhoneAccount and register it with the system. |
static void |
unregisterPhoneAccount(android.content.Context context,
java.lang.String accountName)
Unregister
PhoneAccount with the system. |
public static android.telecom.PhoneAccountHandle createPhoneAccountHandle(android.content.Context context,
java.lang.String accountName)
PhoneAccountHandle for the given parameter.context - The context to use for the ComponentName.accountName - The name of the account. Normaly the SIP URI.PhoneAccountHandle.public static void registerNewPhoneAccount(android.content.Context context,
java.lang.String accountName)
throws java.lang.SecurityException
PhoneAccount and register it with the system.context - The context to use for finding the services and resources.accountName - The name of the account to add - must be an international phonenumber.java.lang.SecurityExceptionpublic static void unregisterPhoneAccount(android.content.Context context,
java.lang.String accountName)
PhoneAccount with the system.context - The context to use for finding the services and resources.accountName - The name of the account. Normaly the SIP URI.public static java.lang.String getAccountName()