Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 08459261 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Add method to reset network types" into rvc-dev

parents c3b84378 a59764ed
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -48078,6 +48078,7 @@ package android.telephony {
    method public android.telephony.SubscriptionPlan build();
    method public static android.telephony.SubscriptionPlan.Builder createNonrecurring(java.time.ZonedDateTime, java.time.ZonedDateTime);
    method public static android.telephony.SubscriptionPlan.Builder createRecurring(java.time.ZonedDateTime, java.time.Period);
    method @NonNull public android.telephony.SubscriptionPlan.Builder resetNetworkTypes();
    method public android.telephony.SubscriptionPlan.Builder setDataLimit(long, int);
    method public android.telephony.SubscriptionPlan.Builder setDataUsage(long, long);
    method @NonNull public android.telephony.SubscriptionPlan.Builder setNetworkTypes(@NonNull int[]);
+10 −0
Original line number Diff line number Diff line
@@ -372,5 +372,15 @@ public final class SubscriptionPlan implements Parcelable {
            plan.networkTypes = Arrays.copyOf(networkTypes, networkTypes.length);
            return this;
        }

        /**
         * Reset any network types that were set with {@link #setNetworkTypes(int[])}.
         * This will make the SubscriptionPlan apply to all network types.
         */
        public @NonNull Builder resetNetworkTypes() {
            plan.networkTypes = Arrays.copyOf(TelephonyManager.getAllNetworkTypes(),
                    TelephonyManager.getAllNetworkTypes().length);
            return this;
        }
    }
}