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

Commit e448e546 authored by Winson's avatar Winson
Browse files

Rename to DomainVerificationInternalUserState

In anticipation of renaming the public API class, rename the internal
one to something that doesn't conflict, so that explicit imports or
aliases don't have to be used.

Bug: 181637637

Test: none, naming refactor

Change-Id: I2b2487265ba783a97697d1aff48568572e96ac3d
parent 5333c755
Loading
Loading
Loading
Loading
+7 −6
Original line number Original line Diff line number Diff line
@@ -35,7 +35,7 @@ import com.android.server.pm.PackageSetting;
import com.android.server.pm.parsing.pkg.AndroidPackage;
import com.android.server.pm.parsing.pkg.AndroidPackage;
import com.android.server.pm.verify.domain.models.DomainVerificationPkgState;
import com.android.server.pm.verify.domain.models.DomainVerificationPkgState;
import com.android.server.pm.verify.domain.models.DomainVerificationStateMap;
import com.android.server.pm.verify.domain.models.DomainVerificationStateMap;
import com.android.server.pm.verify.domain.models.DomainVerificationUserState;
import com.android.server.pm.verify.domain.models.DomainVerificationInternalUserState;


import java.util.Arrays;
import java.util.Arrays;
import java.util.function.Function;
import java.util.function.Function;
@@ -169,7 +169,7 @@ public class DomainVerificationDebug {
        }
        }


        ArraySet<String> allWebDomains = mCollector.collectAllWebDomains(pkg);
        ArraySet<String> allWebDomains = mCollector.collectAllWebDomains(pkg);
        SparseArray<DomainVerificationUserState> userStates =
        SparseArray<DomainVerificationInternalUserState> userStates =
                pkgState.getUserSelectionStates();
                pkgState.getUserSelectionStates();
        if (userId == UserHandle.USER_ALL) {
        if (userId == UserHandle.USER_ALL) {
            int size = userStates.size();
            int size = userStates.size();
@@ -178,13 +178,13 @@ public class DomainVerificationDebug {
                        wasHeaderPrinted);
                        wasHeaderPrinted);
            } else {
            } else {
                for (int index = 0; index < size; index++) {
                for (int index = 0; index < size; index++) {
                    DomainVerificationUserState userState = userStates.valueAt(index);
                    DomainVerificationInternalUserState userState = userStates.valueAt(index);
                    printState(writer, pkgState, userState.getUserId(), userState, reusedSet,
                    printState(writer, pkgState, userState.getUserId(), userState, reusedSet,
                            allWebDomains, wasHeaderPrinted);
                            allWebDomains, wasHeaderPrinted);
                }
                }
            }
            }
        } else {
        } else {
            DomainVerificationUserState userState = userStates.get(userId);
            DomainVerificationInternalUserState userState = userStates.get(userId);
            printState(writer, pkgState, userId, userState, reusedSet, allWebDomains,
            printState(writer, pkgState, userId, userState, reusedSet, allWebDomains,
                    wasHeaderPrinted);
                    wasHeaderPrinted);
        }
        }
@@ -192,8 +192,9 @@ public class DomainVerificationDebug {


    boolean printState(@NonNull IndentingPrintWriter writer,
    boolean printState(@NonNull IndentingPrintWriter writer,
            @NonNull DomainVerificationPkgState pkgState, @UserIdInt int userId,
            @NonNull DomainVerificationPkgState pkgState, @UserIdInt int userId,
            @Nullable DomainVerificationUserState userState, @NonNull ArraySet<String> reusedSet,
            @Nullable DomainVerificationInternalUserState userState,
            @NonNull ArraySet<String> allWebDomains, boolean wasHeaderPrinted) {
            @NonNull ArraySet<String> reusedSet, @NonNull ArraySet<String> allWebDomains,
            boolean wasHeaderPrinted) {
        reusedSet.clear();
        reusedSet.clear();
        reusedSet.addAll(allWebDomains);
        reusedSet.addAll(allWebDomains);
        if (userState != null) {
        if (userState != null) {
+8 −8
Original line number Original line Diff line number Diff line
@@ -27,9 +27,9 @@ import android.util.TypedXmlPullParser;
import android.util.TypedXmlSerializer;
import android.util.TypedXmlSerializer;


import com.android.server.pm.SettingsXml;
import com.android.server.pm.SettingsXml;
import com.android.server.pm.verify.domain.models.DomainVerificationInternalUserState;
import com.android.server.pm.verify.domain.models.DomainVerificationPkgState;
import com.android.server.pm.verify.domain.models.DomainVerificationPkgState;
import com.android.server.pm.verify.domain.models.DomainVerificationStateMap;
import com.android.server.pm.verify.domain.models.DomainVerificationStateMap;
import com.android.server.pm.verify.domain.models.DomainVerificationUserState;


import org.xmlpull.v1.XmlPullParserException;
import org.xmlpull.v1.XmlPullParserException;


@@ -157,7 +157,7 @@ public class DomainVerificationPersistence {
        UUID id = UUID.fromString(idString);
        UUID id = UUID.fromString(idString);


        final ArrayMap<String, Integer> stateMap = new ArrayMap<>();
        final ArrayMap<String, Integer> stateMap = new ArrayMap<>();
        final SparseArray<DomainVerificationUserState> userStates = new SparseArray<>();
        final SparseArray<DomainVerificationInternalUserState> userStates = new SparseArray<>();


        SettingsXml.ChildSection child = section.children();
        SettingsXml.ChildSection child = section.children();
        while (child.moveToNext()) {
        while (child.moveToNext()) {
@@ -176,10 +176,10 @@ public class DomainVerificationPersistence {
    }
    }


    private static void readUserStates(@NonNull SettingsXml.ReadSection section,
    private static void readUserStates(@NonNull SettingsXml.ReadSection section,
            @NonNull SparseArray<DomainVerificationUserState> userStates) {
            @NonNull SparseArray<DomainVerificationInternalUserState> userStates) {
        SettingsXml.ChildSection child = section.children();
        SettingsXml.ChildSection child = section.children();
        while (child.moveToNext(TAG_USER_STATE)) {
        while (child.moveToNext(TAG_USER_STATE)) {
            DomainVerificationUserState userState = createUserStateFromXml(child);
            DomainVerificationInternalUserState userState = createUserStateFromXml(child);
            if (userState != null) {
            if (userState != null) {
                userStates.put(userState.getUserId(), userState);
                userStates.put(userState.getUserId(), userState);
            }
            }
@@ -210,7 +210,7 @@ public class DomainVerificationPersistence {
    }
    }


    private static void writeUserStates(@NonNull SettingsXml.WriteSection parentSection,
    private static void writeUserStates(@NonNull SettingsXml.WriteSection parentSection,
            @NonNull SparseArray<DomainVerificationUserState> states) throws IOException {
            @NonNull SparseArray<DomainVerificationInternalUserState> states) throws IOException {
        int size = states.size();
        int size = states.size();
        if (size == 0) {
        if (size == 0) {
            return;
            return;
@@ -245,7 +245,7 @@ public class DomainVerificationPersistence {
     * entered.
     * entered.
     */
     */
    @Nullable
    @Nullable
    public static DomainVerificationUserState createUserStateFromXml(
    public static DomainVerificationInternalUserState createUserStateFromXml(
            @NonNull SettingsXml.ReadSection section) {
            @NonNull SettingsXml.ReadSection section) {
        int userId = section.getInt(ATTR_USER_ID);
        int userId = section.getInt(ATTR_USER_ID);
        if (userId == -1) {
        if (userId == -1) {
@@ -260,7 +260,7 @@ public class DomainVerificationPersistence {
            readEnabledHosts(child, enabledHosts);
            readEnabledHosts(child, enabledHosts);
        }
        }


        return new DomainVerificationUserState(userId, enabledHosts, allowLinkHandling);
        return new DomainVerificationInternalUserState(userId, enabledHosts, allowLinkHandling);
    }
    }


    private static void readEnabledHosts(@NonNull SettingsXml.ReadSection section,
    private static void readEnabledHosts(@NonNull SettingsXml.ReadSection section,
@@ -275,7 +275,7 @@ public class DomainVerificationPersistence {
    }
    }


    public static void writeUserStateToXml(@NonNull SettingsXml.WriteSection parentSection,
    public static void writeUserStateToXml(@NonNull SettingsXml.WriteSection parentSection,
            @NonNull DomainVerificationUserState userState) throws IOException {
            @NonNull DomainVerificationInternalUserState userState) throws IOException {
        try (SettingsXml.WriteSection section =
        try (SettingsXml.WriteSection section =
                     parentSection.startSection(TAG_USER_STATE)
                     parentSection.startSection(TAG_USER_STATE)
                             .attribute(ATTR_USER_ID, userState.getUserId())
                             .attribute(ATTR_USER_ID, userState.getUserId())
+17 −13
Original line number Original line Diff line number Diff line
@@ -56,9 +56,9 @@ import com.android.server.SystemService;
import com.android.server.compat.PlatformCompat;
import com.android.server.compat.PlatformCompat;
import com.android.server.pm.PackageSetting;
import com.android.server.pm.PackageSetting;
import com.android.server.pm.parsing.pkg.AndroidPackage;
import com.android.server.pm.parsing.pkg.AndroidPackage;
import com.android.server.pm.verify.domain.models.DomainVerificationInternalUserState;
import com.android.server.pm.verify.domain.models.DomainVerificationPkgState;
import com.android.server.pm.verify.domain.models.DomainVerificationPkgState;
import com.android.server.pm.verify.domain.models.DomainVerificationStateMap;
import com.android.server.pm.verify.domain.models.DomainVerificationStateMap;
import com.android.server.pm.verify.domain.models.DomainVerificationUserState;
import com.android.server.pm.verify.domain.proxy.DomainVerificationProxy;
import com.android.server.pm.verify.domain.proxy.DomainVerificationProxy;
import com.android.server.pm.verify.domain.proxy.DomainVerificationProxyUnavailable;
import com.android.server.pm.verify.domain.proxy.DomainVerificationProxyUnavailable;


@@ -405,7 +405,8 @@ public class DomainVerificationService extends SystemService
            final int size = mAttachedPkgStates.size();
            final int size = mAttachedPkgStates.size();
            for (int index = 0; index < size; index++) {
            for (int index = 0; index < size; index++) {
                DomainVerificationPkgState pkgState = mAttachedPkgStates.valueAt(index);
                DomainVerificationPkgState pkgState = mAttachedPkgStates.valueAt(index);
                SparseArray<DomainVerificationUserState> array = pkgState.getUserSelectionStates();
                SparseArray<DomainVerificationInternalUserState> array =
                        pkgState.getUserSelectionStates();
                int arraySize = array.size();
                int arraySize = array.size();
                for (int arrayIndex = 0; arrayIndex < arraySize; arrayIndex++) {
                for (int arrayIndex = 0; arrayIndex < arraySize; arrayIndex++) {
                    array.valueAt(arrayIndex).removeHost(domain);
                    array.valueAt(arrayIndex).removeHost(domain);
@@ -484,7 +485,8 @@ public class DomainVerificationService extends SystemService


            DomainVerificationPkgState pkgState = getAndValidateAttachedLocked(domainSetId, domains,
            DomainVerificationPkgState pkgState = getAndValidateAttachedLocked(domainSetId, domains,
                    false /* forAutoVerify */, callingUid, userId);
                    false /* forAutoVerify */, callingUid, userId);
            DomainVerificationUserState userState = pkgState.getOrCreateUserSelectionState(userId);
            DomainVerificationInternalUserState userState =
                    pkgState.getOrCreateUserSelectionState(userId);


            // Disable other packages if approving this one. Note that this check is only done for
            // Disable other packages if approving this one. Note that this check is only done for
            // enabling. This allows an escape hatch in case multiple packages somehow get selected.
            // enabling. This allows an escape hatch in case multiple packages somehow get selected.
@@ -524,7 +526,7 @@ public class DomainVerificationService extends SystemService
                            continue;
                            continue;
                        }
                        }


                        DomainVerificationUserState approvedUserState =
                        DomainVerificationInternalUserState approvedUserState =
                                approvedPkgState.getUserSelectionState(userId);
                                approvedPkgState.getUserSelectionState(userId);
                        if (approvedUserState == null) {
                        if (approvedUserState == null) {
                            continue;
                            continue;
@@ -607,7 +609,7 @@ public class DomainVerificationService extends SystemService


        if (userId == UserHandle.USER_ALL) {
        if (userId == UserHandle.USER_ALL) {
            for (int aUserId : mConnection.getAllUserIds()) {
            for (int aUserId : mConnection.getAllUserIds()) {
                DomainVerificationUserState userState =
                DomainVerificationInternalUserState userState =
                        pkgState.getOrCreateUserSelectionState(aUserId);
                        pkgState.getOrCreateUserSelectionState(aUserId);
                if (enabled) {
                if (enabled) {
                    userState.addHosts(domains);
                    userState.addHosts(domains);
@@ -616,7 +618,8 @@ public class DomainVerificationService extends SystemService
                }
                }
            }
            }
        } else {
        } else {
            DomainVerificationUserState userState = pkgState.getOrCreateUserSelectionState(userId);
            DomainVerificationInternalUserState userState =
                    pkgState.getOrCreateUserSelectionState(userId);
            if (enabled) {
            if (enabled) {
                userState.addHosts(domains);
                userState.addHosts(domains);
            } else {
            } else {
@@ -649,7 +652,7 @@ public class DomainVerificationService extends SystemService


            Map<String, Integer> domains = new ArrayMap<>(webDomainsSize);
            Map<String, Integer> domains = new ArrayMap<>(webDomainsSize);
            ArrayMap<String, Integer> stateMap = pkgState.getStateMap();
            ArrayMap<String, Integer> stateMap = pkgState.getStateMap();
            DomainVerificationUserState userState = pkgState.getUserSelectionState(userId);
            DomainVerificationInternalUserState userState = pkgState.getUserSelectionState(userId);
            Set<String> enabledHosts = userState == null ? emptySet() : userState.getEnabledHosts();
            Set<String> enabledHosts = userState == null ? emptySet() : userState.getEnabledHosts();


            for (int index = 0; index < webDomainsSize; index++) {
            for (int index = 0; index < webDomainsSize; index++) {
@@ -765,7 +768,7 @@ public class DomainVerificationService extends SystemService
            AndroidPackage newPkg = newPkgSetting.getPkg();
            AndroidPackage newPkg = newPkgSetting.getPkg();


            ArrayMap<String, Integer> newStateMap = new ArrayMap<>();
            ArrayMap<String, Integer> newStateMap = new ArrayMap<>();
            SparseArray<DomainVerificationUserState> newUserStates = new SparseArray<>();
            SparseArray<DomainVerificationInternalUserState> newUserStates = new SparseArray<>();


            if (oldPkgState == null || oldPkg == null || newPkg == null) {
            if (oldPkgState == null || oldPkg == null || newPkg == null) {
                // Should be impossible, but to be safe, continue with a new blank state instead
                // Should be impossible, but to be safe, continue with a new blank state instead
@@ -808,7 +811,7 @@ public class DomainVerificationService extends SystemService
                }
                }
            }
            }


            SparseArray<DomainVerificationUserState> oldUserStates =
            SparseArray<DomainVerificationInternalUserState> oldUserStates =
                    oldPkgState.getUserSelectionStates();
                    oldPkgState.getUserSelectionStates();
            int oldUserStatesSize = oldUserStates.size();
            int oldUserStatesSize = oldUserStates.size();
            if (oldUserStatesSize > 0) {
            if (oldUserStatesSize > 0) {
@@ -816,13 +819,14 @@ public class DomainVerificationService extends SystemService
                for (int oldUserStatesIndex = 0; oldUserStatesIndex < oldUserStatesSize;
                for (int oldUserStatesIndex = 0; oldUserStatesIndex < oldUserStatesSize;
                        oldUserStatesIndex++) {
                        oldUserStatesIndex++) {
                    int userId = oldUserStates.keyAt(oldUserStatesIndex);
                    int userId = oldUserStates.keyAt(oldUserStatesIndex);
                    DomainVerificationUserState oldUserState = oldUserStates.valueAt(
                    DomainVerificationInternalUserState oldUserState = oldUserStates.valueAt(
                            oldUserStatesIndex);
                            oldUserStatesIndex);
                    ArraySet<String> oldEnabledHosts = oldUserState.getEnabledHosts();
                    ArraySet<String> oldEnabledHosts = oldUserState.getEnabledHosts();
                    ArraySet<String> newEnabledHosts = new ArraySet<>(oldEnabledHosts);
                    ArraySet<String> newEnabledHosts = new ArraySet<>(oldEnabledHosts);
                    newEnabledHosts.retainAll(newWebDomains);
                    newEnabledHosts.retainAll(newWebDomains);
                    DomainVerificationUserState newUserState = new DomainVerificationUserState(
                    DomainVerificationInternalUserState newUserState =
                            userId, newEnabledHosts, oldUserState.isLinkHandlingAllowed());
                            new DomainVerificationInternalUserState(userId, newEnabledHosts,
                                    oldUserState.isLinkHandlingAllowed());
                    newUserStates.put(userId, newUserState);
                    newUserStates.put(userId, newUserState);
                }
                }
            }
            }
@@ -1515,7 +1519,7 @@ public class DomainVerificationService extends SystemService
                return APPROVAL_LEVEL_NONE;
                return APPROVAL_LEVEL_NONE;
            }
            }


            DomainVerificationUserState userState = pkgState.getUserSelectionState(userId);
            DomainVerificationInternalUserState userState = pkgState.getUserSelectionState(userId);


            if (userState != null && !userState.isLinkHandlingAllowed()) {
            if (userState != null && !userState.isLinkHandlingAllowed()) {
                if (DEBUG_APPROVAL) {
                if (DEBUG_APPROVAL) {
+7 −6
Original line number Original line Diff line number Diff line
@@ -29,9 +29,9 @@ import android.util.TypedXmlSerializer;


import com.android.internal.annotations.GuardedBy;
import com.android.internal.annotations.GuardedBy;
import com.android.internal.annotations.VisibleForTesting;
import com.android.internal.annotations.VisibleForTesting;
import com.android.server.pm.verify.domain.models.DomainVerificationInternalUserState;
import com.android.server.pm.verify.domain.models.DomainVerificationPkgState;
import com.android.server.pm.verify.domain.models.DomainVerificationPkgState;
import com.android.server.pm.verify.domain.models.DomainVerificationStateMap;
import com.android.server.pm.verify.domain.models.DomainVerificationStateMap;
import com.android.server.pm.verify.domain.models.DomainVerificationUserState;


import org.xmlpull.v1.XmlPullParserException;
import org.xmlpull.v1.XmlPullParserException;


@@ -216,21 +216,22 @@ class DomainVerificationSettings {
            }
            }
        }
        }


        SparseArray<DomainVerificationUserState> oldSelectionStates =
        SparseArray<DomainVerificationInternalUserState> oldSelectionStates =
                oldState.getUserSelectionStates();
                oldState.getUserSelectionStates();


        SparseArray<DomainVerificationUserState> newSelectionStates =
        SparseArray<DomainVerificationInternalUserState> newSelectionStates =
                newState.getUserSelectionStates();
                newState.getUserSelectionStates();


        DomainVerificationUserState newUserState = newSelectionStates.get(UserHandle.USER_SYSTEM);
        DomainVerificationInternalUserState newUserState =
                newSelectionStates.get(UserHandle.USER_SYSTEM);
        if (newUserState != null) {
        if (newUserState != null) {
            ArraySet<String> newEnabledHosts = newUserState.getEnabledHosts();
            ArraySet<String> newEnabledHosts = newUserState.getEnabledHosts();
            DomainVerificationUserState oldUserState =
            DomainVerificationInternalUserState oldUserState =
                    oldSelectionStates.get(UserHandle.USER_SYSTEM);
                    oldSelectionStates.get(UserHandle.USER_SYSTEM);


            boolean linkHandlingAllowed = newUserState.isLinkHandlingAllowed();
            boolean linkHandlingAllowed = newUserState.isLinkHandlingAllowed();
            if (oldUserState == null) {
            if (oldUserState == null) {
                oldUserState = new DomainVerificationUserState(UserHandle.USER_SYSTEM,
                oldUserState = new DomainVerificationInternalUserState(UserHandle.USER_SYSTEM,
                        newEnabledHosts, linkHandlingAllowed);
                        newEnabledHosts, linkHandlingAllowed);
                oldSelectionStates.put(UserHandle.USER_SYSTEM, oldUserState);
                oldSelectionStates.put(UserHandle.USER_SYSTEM, oldUserState);
            } else {
            } else {
+17 −18
Original line number Original line Diff line number Diff line
@@ -29,7 +29,7 @@ import java.util.Set;
 * when a web URL Intent is sent and the application is the highest priority for that domain.
 * when a web URL Intent is sent and the application is the highest priority for that domain.
 */
 */
@DataClass(genSetters = true, genEqualsHashCode = true, genToString = true, genBuilder = false)
@DataClass(genSetters = true, genEqualsHashCode = true, genToString = true, genBuilder = false)
public class DomainVerificationUserState {
public class DomainVerificationInternalUserState {


    @UserIdInt
    @UserIdInt
    private final int mUserId;
    private final int mUserId;
@@ -43,32 +43,32 @@ public class DomainVerificationUserState {
     */
     */
    private boolean mLinkHandlingAllowed = true;
    private boolean mLinkHandlingAllowed = true;


    public DomainVerificationUserState(@UserIdInt int userId) {
    public DomainVerificationInternalUserState(@UserIdInt int userId) {
        mUserId = userId;
        mUserId = userId;
        mEnabledHosts = new ArraySet<>();
        mEnabledHosts = new ArraySet<>();
    }
    }


    public DomainVerificationUserState addHosts(@NonNull ArraySet<String> newHosts) {
    public DomainVerificationInternalUserState addHosts(@NonNull ArraySet<String> newHosts) {
        mEnabledHosts.addAll(newHosts);
        mEnabledHosts.addAll(newHosts);
        return this;
        return this;
    }
    }


    public DomainVerificationUserState addHosts(@NonNull Set<String> newHosts) {
    public DomainVerificationInternalUserState addHosts(@NonNull Set<String> newHosts) {
        mEnabledHosts.addAll(newHosts);
        mEnabledHosts.addAll(newHosts);
        return this;
        return this;
    }
    }


    public DomainVerificationUserState removeHost(String host) {
    public DomainVerificationInternalUserState removeHost(String host) {
        mEnabledHosts.remove(host);
        mEnabledHosts.remove(host);
        return this;
        return this;
    }
    }


    public DomainVerificationUserState removeHosts(@NonNull ArraySet<String> newHosts) {
    public DomainVerificationInternalUserState removeHosts(@NonNull ArraySet<String> newHosts) {
        mEnabledHosts.removeAll(newHosts);
        mEnabledHosts.removeAll(newHosts);
        return this;
        return this;
    }
    }


    public DomainVerificationUserState removeHosts(@NonNull Set<String> newHosts) {
    public DomainVerificationInternalUserState removeHosts(@NonNull Set<String> newHosts) {
        mEnabledHosts.removeAll(newHosts);
        mEnabledHosts.removeAll(newHosts);
        return this;
        return this;
    }
    }
@@ -81,8 +81,7 @@ public class DomainVerificationUserState {
    // CHECKSTYLE:OFF Generated code
    // CHECKSTYLE:OFF Generated code
    //
    //
    // To regenerate run:
    // To regenerate run:
    // $ codegen $ANDROID_BUILD_TOP/frameworks/base/services/core/java/com/android/server/pm
    // $ codegen $ANDROID_BUILD_TOP/frameworks/base/services/core/java/com/android/server/pm/verify/domain/models/DomainVerificationInternalUserState.java
    // /verify/domain/models/DomainVerificationUserState.java
    //
    //
    // To exclude the generated code from IntelliJ auto-formatting enable (one-time):
    // To exclude the generated code from IntelliJ auto-formatting enable (one-time):
    //   Settings > Editor > Code Style > Formatter Control
    //   Settings > Editor > Code Style > Formatter Control
@@ -90,7 +89,7 @@ public class DomainVerificationUserState {




    /**
    /**
     * Creates a new DomainVerificationUserState.
     * Creates a new DomainVerificationInternalUserState.
     *
     *
     * @param enabledHosts
     * @param enabledHosts
     *   List of domains which have been enabled by the user. *
     *   List of domains which have been enabled by the user. *
@@ -98,7 +97,7 @@ public class DomainVerificationUserState {
     *   Whether to allow this package to automatically open links by auto verification.
     *   Whether to allow this package to automatically open links by auto verification.
     */
     */
    @DataClass.Generated.Member
    @DataClass.Generated.Member
    public DomainVerificationUserState(
    public DomainVerificationInternalUserState(
            @UserIdInt int userId,
            @UserIdInt int userId,
            @NonNull ArraySet<String> enabledHosts,
            @NonNull ArraySet<String> enabledHosts,
            boolean linkHandlingAllowed) {
            boolean linkHandlingAllowed) {
@@ -138,7 +137,7 @@ public class DomainVerificationUserState {
     * Whether to allow this package to automatically open links by auto verification.
     * Whether to allow this package to automatically open links by auto verification.
     */
     */
    @DataClass.Generated.Member
    @DataClass.Generated.Member
    public @NonNull DomainVerificationUserState setLinkHandlingAllowed( boolean value) {
    public @NonNull DomainVerificationInternalUserState setLinkHandlingAllowed( boolean value) {
        mLinkHandlingAllowed = value;
        mLinkHandlingAllowed = value;
        return this;
        return this;
    }
    }
@@ -149,7 +148,7 @@ public class DomainVerificationUserState {
        // You can override field toString logic by defining methods like:
        // You can override field toString logic by defining methods like:
        // String fieldNameToString() { ... }
        // String fieldNameToString() { ... }


        return "DomainVerificationUserState { " +
        return "DomainVerificationInternalUserState { " +
                "userId = " + mUserId + ", " +
                "userId = " + mUserId + ", " +
                "enabledHosts = " + mEnabledHosts + ", " +
                "enabledHosts = " + mEnabledHosts + ", " +
                "linkHandlingAllowed = " + mLinkHandlingAllowed +
                "linkHandlingAllowed = " + mLinkHandlingAllowed +
@@ -160,13 +159,13 @@ public class DomainVerificationUserState {
    @DataClass.Generated.Member
    @DataClass.Generated.Member
    public boolean equals(@android.annotation.Nullable Object o) {
    public boolean equals(@android.annotation.Nullable Object o) {
        // You can override field equality logic by defining either of the methods like:
        // You can override field equality logic by defining either of the methods like:
        // boolean fieldNameEquals(DomainVerificationUserState other) { ... }
        // boolean fieldNameEquals(DomainVerificationInternalUserState other) { ... }
        // boolean fieldNameEquals(FieldType otherValue) { ... }
        // boolean fieldNameEquals(FieldType otherValue) { ... }


        if (this == o) return true;
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        if (o == null || getClass() != o.getClass()) return false;
        @SuppressWarnings("unchecked")
        @SuppressWarnings("unchecked")
        DomainVerificationUserState that = (DomainVerificationUserState) o;
        DomainVerificationInternalUserState that = (DomainVerificationInternalUserState) o;
        //noinspection PointlessBooleanExpression
        //noinspection PointlessBooleanExpression
        return true
        return true
                && mUserId == that.mUserId
                && mUserId == that.mUserId
@@ -188,10 +187,10 @@ public class DomainVerificationUserState {
    }
    }


    @DataClass.Generated(
    @DataClass.Generated(
            time = 1612894390039L,
            time = 1614714563905L,
            codegenVersion = "1.0.22",
            codegenVersion = "1.0.22",
            sourceFile = "frameworks/base/services/core/java/com/android/server/pm/verify/domain/models/DomainVerificationUserState.java",
            sourceFile = "frameworks/base/services/core/java/com/android/server/pm/verify/domain/models/DomainVerificationInternalUserState.java",
            inputSignatures = "private final @android.annotation.UserIdInt int mUserId\nprivate final @android.annotation.NonNull android.util.ArraySet<java.lang.String> mEnabledHosts\nprivate  boolean mLinkHandlingAllowed\npublic  com.android.server.pm.verify.domain.models.DomainVerificationUserState addHosts(android.util.ArraySet<java.lang.String>)\npublic  com.android.server.pm.verify.domain.models.DomainVerificationUserState addHosts(java.util.Set<java.lang.String>)\npublic  com.android.server.pm.verify.domain.models.DomainVerificationUserState removeHosts(android.util.ArraySet<java.lang.String>)\npublic  com.android.server.pm.verify.domain.models.DomainVerificationUserState removeHosts(java.util.Set<java.lang.String>)\nclass DomainVerificationUserState extends java.lang.Object implements []\n@com.android.internal.util.DataClass(genSetters=true, genEqualsHashCode=true, genToString=true, genBuilder=false)")
            inputSignatures = "private final @android.annotation.UserIdInt int mUserId\nprivate final @android.annotation.NonNull android.util.ArraySet<java.lang.String> mEnabledHosts\nprivate  boolean mLinkHandlingAllowed\npublic  com.android.server.pm.verify.domain.models.DomainVerificationInternalUserState addHosts(android.util.ArraySet<java.lang.String>)\npublic  com.android.server.pm.verify.domain.models.DomainVerificationInternalUserState addHosts(java.util.Set<java.lang.String>)\npublic  com.android.server.pm.verify.domain.models.DomainVerificationInternalUserState removeHost(java.lang.String)\npublic  com.android.server.pm.verify.domain.models.DomainVerificationInternalUserState removeHosts(android.util.ArraySet<java.lang.String>)\npublic  com.android.server.pm.verify.domain.models.DomainVerificationInternalUserState removeHosts(java.util.Set<java.lang.String>)\nclass DomainVerificationInternalUserState extends java.lang.Object implements []\n@com.android.internal.util.DataClass(genSetters=true, genEqualsHashCode=true, genToString=true, genBuilder=false)")
    @Deprecated
    @Deprecated
    private void __metadata() {}
    private void __metadata() {}


Loading