[pm] refactor mAppIds to be more readable

Use explicit key/values instead of implicit indices which were
error-prone.

Notice that this is a no-op change and should not introduce any
different behavior.

+ Unit tests
+ Clean up unused methods

Test: com.android.server.pm.PackageManagerSettingsTests
BUG: 223215503
Change-Id: Ib7b8e208f368a1e3155f1f74f007b33e70b3d167
3 files changed