Closed vsex7 closed 4 months ago
UserManager#USER_TYPE_PROFILE_CLONE
@SystemApi
public static final String USER_TYPE_PROFILE_CLONE = "android.os.usertype.profile.CLONE";
UserManager#createProfileForUser
/**
* Creates a user with the specified name and options as a profile of another user.
*
* @param name the user's name
* @param userType the type of user, such as {@link UserManager#USER_TYPE_PROFILE_MANAGED}.
* @param flags UserInfo flags that specify user properties.
* @param userId new user will be a profile of this user.
*
* @return the {@link UserInfo} object for the created user, or null if the user could not be created.
* @hide
*/
@RequiresPermission(anyOf = {Manifest.permission.MANAGE_USERS, Manifest.permission.CREATE_USERS})
public @Nullable UserInfo createProfileForUser(String name, @NonNull String userType, @UserInfoFlag int flags, @UserIdInt int userId) {
return createProfileForUser(name, userType, flags, userId, null);
}
If you want to create mutiple/unlimited users with OwnDroid, you can activate OwnDroid as Device owner, then create managed users in User manager
.
Type android.os.usertype.profile.CLONE Please provide support