UserManagerCompat

Added in 1.1.0

public class UserManagerCompat


Helper for accessing features in android.os.UserManager in a backwards compatible fashion.

Summary

Public methods

static boolean

Return whether the calling user is running in an "unlocked" state.

Public methods

isUserUnlocked

Added in 1.1.0
public static boolean isUserUnlocked(@NonNull Context context)

Return whether the calling user is running in an "unlocked" state. A user is unlocked only after they've entered their credentials (such as a lock pattern or PIN), and credential-encrypted private app data storage is available.