UserSwitcher.UserTypeMode

public static final enum UserSwitcher.UserTypeMode
extends Enum<UserSwitcher.UserTypeMode>

java.lang.Object
   ↳ java.lang.Enum<com.android.tradefed.device.UserSwitcher.UserTypeMode>
     ↳ com.android.tradefed.device.UserSwitcher.UserTypeMode


Defines the expected behavior depending on the UserType associated with it.

NOTE: currently the switchability is only checked when the user type is UserType.SYSTEM.

Summary

Enum values

UserSwitcher.UserTypeMode  LEGACY

This field is deprecated. TODO(b/419372865): remove once tests that can be ignored when the HSU cannot be switched to are changed to use mode REQUIRED_ONLY. 

UserSwitcher.UserTypeMode  REQUIRED_AND_SWITCHABLE

The user must exist and be switchable to, otherwise the preparer will fail. 

UserSwitcher.UserTypeMode  REQUIRED_ONLY

The user must exist, but the test won't switch users if it's not switchable to. 

Public methods

static UserSwitcher.UserTypeMode valueOf(String name)
static final UserTypeMode[] values()

Enum values

LEGACY

public static final UserSwitcher.UserTypeMode LEGACY

This field is deprecated.
TODO(b/419372865): remove once tests that can be ignored when the HSU cannot be switched to are changed to use mode REQUIRED_ONLY.

If the user type is SYSTEM and the device doesn't allow switching to the system user, it will switch to the first full user instead.

REQUIRED_AND_SWITCHABLE

public static final UserSwitcher.UserTypeMode REQUIRED_AND_SWITCHABLE

The user must exist and be switchable to, otherwise the preparer will fail.

REQUIRED_ONLY

public static final UserSwitcher.UserTypeMode REQUIRED_ONLY

The user must exist, but the test won't switch users if it's not switchable to.

Public methods

valueOf

public static UserSwitcher.UserTypeMode valueOf (String name)

Parameters
name String

Returns
UserSwitcher.UserTypeMode

values

public static final UserTypeMode[] values ()

Returns
UserTypeMode[]