Use SubscriptionId instead of SubId

Rename the methods and arguments in ServiceStateTable to use
SubscriptionId instead of SubId.

Fixes: 35766624
Test: Existing unit tests pass
Change-Id: Ic837535b431c19d952e065b742d678152afafd57
Merged-In: Ic837535b431c19d952e065b742d678152afafd57
diff --git a/src/java/android/provider/Telephony.java b/src/java/android/provider/Telephony.java
index afeca37..a91e05e 100644
--- a/src/java/android/provider/Telephony.java
+++ b/src/java/android/provider/Telephony.java
@@ -3007,12 +3007,12 @@
          * Note, however, that using a {@link JobService} does not guarantee timely delivery of
          * updates to the {@link Uri}.
          *
-         * @param subId the subId to receive updates on
+         * @param subscriptionId the subscriptionId to receive updates on
          * @param field the ServiceState field to receive updates on
          * @return the Uri used to observe {@link ServiceState} changes
          */
-        public static Uri getUriForSubIdAndField(int subId, String field) {
-            return CONTENT_URI.buildUpon().appendEncodedPath(String.valueOf(subId))
+        public static Uri getUriForSubscriptionIdAndField(int subscriptionId, String field) {
+            return CONTENT_URI.buildUpon().appendEncodedPath(String.valueOf(subscriptionId))
                     .appendEncodedPath(field).build();
         }
 
@@ -3026,11 +3026,12 @@
          * Note, however, that using a {@link JobService} does not guarantee timely delivery of
          * updates to the {@link Uri}.
          *
-         * @param subId the subId to receive updates on
+         * @param subscriptionId the subscriptionId to receive updates on
          * @return the Uri used to observe {@link ServiceState} changes
          */
-        public static Uri getUriForSubId(int subId) {
-            return CONTENT_URI.buildUpon().appendEncodedPath(String.valueOf(subId)).build();
+        public static Uri getUriForSubscriptionId(int subscriptionId) {
+            return CONTENT_URI.buildUpon()
+                    .appendEncodedPath(String.valueOf(subscriptionId)).build();
         }
 
         /**
diff --git a/src/java/com/android/internal/telephony/ServiceStateTracker.java b/src/java/com/android/internal/telephony/ServiceStateTracker.java
index e49531c..dd4624b 100644
--- a/src/java/com/android/internal/telephony/ServiceStateTracker.java
+++ b/src/java/com/android/internal/telephony/ServiceStateTracker.java
@@ -17,7 +17,7 @@
 package com.android.internal.telephony;
 
 import static android.provider.Telephony.ServiceStateTable.getContentValuesForServiceState;
-import static android.provider.Telephony.ServiceStateTable.getUriForSubId;
+import static android.provider.Telephony.ServiceStateTable.getUriForSubscriptionId;
 
 import static com.android.internal.telephony.CarrierActionAgent.CARRIER_ACTION_SET_RADIO_ENABLED;
 
@@ -2859,8 +2859,9 @@
             mPhone.notifyServiceStateChanged(mSS);
 
             // insert into ServiceStateProvider. This will trigger apps to wake through JobScheduler
-            mPhone.getContext().getContentResolver().insert(getUriForSubId(mPhone.getSubId()),
-                    getContentValuesForServiceState(mSS));
+            mPhone.getContext().getContentResolver()
+                    .insert(getUriForSubscriptionId(mPhone.getSubId()),
+                            getContentValuesForServiceState(mSS));
 
             TelephonyMetrics.getInstance().writeServiceStateChanged(mPhone.getPhoneId(), mSS);
         }