Strangely there isn't a question on SO regarding this topic. At least I couldn't find one.
Like Windows & Linux, Android too allows us to have multiple user accounts on the same device/computer:
Each user is the FIRST (or primary) Google account with which the device/user partition was activated. Hence, one way to get the name/email associated with this user is through Google Sign-In:
My question is, is there a way to get at least the name (if not the email) of the device user? Without using Google Sign-In, which requires both the Play Services library and the
GET_ACCOUNTS
permission?
There should be some Android API or Provider
that tells us the name of the current device user. I've already looked at the following documents:
.... and I couldn't find anything there.
Does anyone know of a way to get the name/email of the primary Google account on the current user/partition? WITHOUT Google Sign-In, which requires Play Services? Is there some Java/Android API that gives us the account details for the current user?
Related:
1. How to get active account Id in android multi user