diff options
Diffstat (limited to 'telephony/java/com')
4 files changed, 51 insertions, 56 deletions
diff --git a/telephony/java/com/android/internal/telephony/ISub.aidl b/telephony/java/com/android/internal/telephony/ISub.aidl index 829620a..d82c492 100755 --- a/telephony/java/com/android/internal/telephony/ISub.aidl +++ b/telephony/java/com/android/internal/telephony/ISub.aidl @@ -17,41 +17,42 @@ package com.android.internal.telephony; import android.app.PendingIntent; -import android.telephony.SubInfoRecord; +import android.telephony.SubscriptionInfo; +import com.android.internal.telephony.ISubscriptionListener; interface ISub { /** - * Get the SubInfoRecord according to an index - * @param subId The unique SubInfoRecord index in database - * @return SubInfoRecord, maybe null + * Get the SubscriptionInfo according to an index + * @param subId The unique SubscriptionInfo index in database + * @return SubscriptionInfo, maybe null */ - SubInfoRecord getSubInfoForSubscriber(int subId); + SubscriptionInfo getSubInfoForSubscriber(int subId); /** - * Get the SubInfoRecord according to an IccId + * Get the SubscriptionInfo according to an IccId * @param iccId the IccId of SIM card - * @return SubInfoRecord, maybe null + * @return SubscriptionInfo, maybe null */ - List<SubInfoRecord> getSubInfoUsingIccId(String iccId); + List<SubscriptionInfo> getSubInfoUsingIccId(String iccId); /** - * Get the SubInfoRecord according to slotId + * Get the SubscriptionInfo according to slotId * @param slotId the slot which the SIM is inserted - * @return SubInfoRecord, maybe null + * @return SubscriptionInfo, maybe null */ - List<SubInfoRecord> getSubInfoUsingSlotId(int slotId); + List<SubscriptionInfo> getSubInfoUsingSlotId(int slotId); /** - * Get all the SubInfoRecord(s) in subinfo database + * Get all the SubscriptionInfo(s) in subinfo database * @return Array list of all SubInfoRecords in database, include thsoe that were inserted before */ - List<SubInfoRecord> getAllSubInfoList(); + List<SubscriptionInfo> getAllSubInfoList(); /** - * Get the SubInfoRecord(s) of the currently inserted SIM(s) - * @return Array list of currently inserted SubInfoRecord(s) + * Get the SubscriptionInfo(s) of the currently inserted SIM(s) + * @return Array list of currently inserted SubscriptionInfo(s) */ - List<SubInfoRecord> getActiveSubInfoList(); + List<SubscriptionInfo> getActiveSubInfoList(); /** * Get the SUB count of all SUB(s) in subinfo database @@ -66,7 +67,7 @@ interface ISub { int getActiveSubInfoCount(); /** - * Add a new SubInfoRecord to subinfo database if needed + * Add a new SubscriptionInfo to subinfo database if needed * @param iccId the IccId of the SIM card * @param slotId the slot which the SIM is inserted * @return the URL of the newly created row or the updated row @@ -76,7 +77,7 @@ interface ISub { /** * Set SIM icon tint color by simInfo index * @param tint the icon tint color of the SIM - * @param subId the unique SubInfoRecord index in database + * @param subId the unique SubscriptionInfo index in database * @return the number of records updated */ int setIconTint(int tint, int subId); @@ -84,7 +85,7 @@ interface ISub { /** * Set display name by simInfo index * @param displayName the display name of SIM card - * @param subId the unique SubInfoRecord index in database + * @param subId the unique SubscriptionInfo index in database * @return the number of records updated */ int setDisplayName(String displayName, int subId); @@ -92,7 +93,7 @@ interface ISub { /** * Set display name by simInfo index with name source * @param displayName the display name of SIM card - * @param subId the unique SubInfoRecord index in database + * @param subId the unique SubscriptionInfo index in database * @param nameSource, 0: DEFAULT_SOURCE, 1: SIM_SOURCE, 2: USER_INPUT * @return the number of records updated */ @@ -101,7 +102,7 @@ interface ISub { /** * Set phone number by subId * @param number the phone number of the SIM - * @param subId the unique SubInfoRecord index in database + * @param subId the unique SubscriptionInfo index in database * @return the number of records updated */ int setDisplayNumber(String number, int subId); @@ -109,7 +110,7 @@ interface ISub { /** * Set data roaming by simInfo index * @param roaming 0:Don't allow data when roaming, 1:Allow data when roaming - * @param subId the unique SubInfoRecord index in database + * @param subId the unique SubscriptionInfo index in database * @return the number of records updated */ int setDataRoaming(int roaming, int subId); diff --git a/telephony/java/com/android/internal/telephony/ISubscriptionListener.aidl b/telephony/java/com/android/internal/telephony/ISubscriptionListener.aidl new file mode 100644 index 0000000..4ccdea5 --- /dev/null +++ b/telephony/java/com/android/internal/telephony/ISubscriptionListener.aidl @@ -0,0 +1,24 @@ +/* + * Copyright (C) 2014 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.android.internal.telephony; + +import android.telephony.SubscriptionInfo; + +oneway interface ISubscriptionListener { + void onSubscriptionInfoChanged(); +} + diff --git a/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl b/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl index ee3f8b0..1a1f8fe 100644 --- a/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl +++ b/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl @@ -27,8 +27,11 @@ import android.telephony.SignalStrength; import android.telephony.CellInfo; import android.telephony.VoLteServiceState; import com.android.internal.telephony.IPhoneStateListener; +import com.android.internal.telephony.ISubscriptionListener; interface ITelephonyRegistry { + void registerSubscriptionListener(String pkg, ISubscriptionListener callback, int events); + void unregisterSubscriptionListener(String pkg, ISubscriptionListener callback); void listen(String pkg, IPhoneStateListener callback, int events, boolean notifyNow); void listenForSubscriber(in int subId, String pkg, IPhoneStateListener callback, int events, boolean notifyNow); @@ -63,4 +66,5 @@ interface ITelephonyRegistry { void notifyDataConnectionRealTimeInfo(in DataConnectionRealTimeInfo dcRtInfo); void notifyVoLteServiceStateChanged(in VoLteServiceState lteState); void notifyOemHookRawEventForSubscriber(in int subId, in byte[] rawData); + void notifySubscriptionInfoChanged(); } diff --git a/telephony/java/com/android/internal/telephony/TelephonyIntents.java b/telephony/java/com/android/internal/telephony/TelephonyIntents.java index d05e7d1..c67e5d7 100644 --- a/telephony/java/com/android/internal/telephony/TelephonyIntents.java +++ b/telephony/java/com/android/internal/telephony/TelephonyIntents.java @@ -312,27 +312,7 @@ public class TelephonyIntents { public static final String EXTRA_SPN = "spn"; /** - * <p>Broadcast Action: It indicates one column of a siminfo record has been changed - * The intent will have the following extra values:</p> - * <ul> - * <li><em>columnName</em> - The siminfo column that is updated.</li> - * <li><em>stringContent</em> - The string value of the updated column.</li> - * <li><em>intContent</em> - The int value of the updated column.</li> - * </ul> - * <p class="note">This is a protected intent that can only be sent - * by the system. - */ - public static final String ACTION_SIMINFO_CONTENT_CHANGE - = "android.intent.action.ACTION_SIMINFO_CONTENT_CHANGE"; - - /** * <p>Broadcast Action: It indicates one column of a subinfo record has been changed - * The intent will have the following extra values:</p> - * <ul> - * <li><em>columnName</em> - The siminfo column that is updated.</li> - * <li><em>stringContent</em> - The string value of the updated column.</li> - * <li><em>intContent</em> - The int value of the updated column.</li> - * </ul> * <p class="note">This is a protected intent that can only be sent * by the system. */ @@ -340,28 +320,14 @@ public class TelephonyIntents { = "android.intent.action.ACTION_SUBINFO_CONTENT_CHANGE"; /** - * <p>Broadcast Action: It indicates siminfo update is completed when SIM inserted state change - * The intent will have the following extra values:</p> - * <p class="note">This is a protected intent that can only be sent - * by the system. - */ - public static final String ACTION_SIMINFO_UPDATED - = "android.intent.action.ACTION_SIMINFO_UPDATED"; - - /** * <p>Broadcast Action: It indicates subinfo record update is completed * when SIM inserted state change - * The intent will have the following extra values:</p> * <p class="note">This is a protected intent that can only be sent * by the system. */ public static final String ACTION_SUBINFO_RECORD_UPDATED = "android.intent.action.ACTION_SUBINFO_RECORD_UPDATED"; - public static final String EXTRA_COLUMN_NAME = "columnName"; - public static final String EXTRA_INT_CONTENT = "intContent"; - public static final String EXTRA_STRING_CONTENT = "stringContent"; - /** * Broadcast Action: The default subscription has changed. This has the following * extra values:</p> |