Add removeUserOrSetEphemeral

To support removing a user as soon as possible, we introduce an
API that will remove a non-current user immediately or mark the
current user as ephemeral so that it is removed on user switch
or reboot.

This API will be used by CarService, which runs in a different
process, so the API must be exposed on UserManager (instead of
just UserManagerInternal).

Bug: 155913815
Test: adb shell pm remove-user --set-ephemeral-if-in-use <uid>
Change-Id: I5975a70c439bd7892939bcee65be2f2dd85026ed
5 files changed