-1

How can I get the lists of installed Apps in Android similar to what we can see in phone settings within installed Apps. Also I would like to know theirs location and if possible permissions. I'm using Java language with Android Studio.

Aastha Doshi
  • 147
  • 1
  • 14
Gerard
  • 13
  • 4

2 Answers2

0

You can use this command to get a list of installed apps:

List<ApplicationInfo> infos = getPackageManager().getInstalledApplications(PackageManager.GET_META_DATA);

ApplicationInfo contains a lot of information about the app, like the name, the packagename, minSdkVersion, some paths and a lot more.

Headcracker
  • 522
  • 4
  • 19
0

This snippet would help you.

 Intent mainIntent = new Intent(Intent.ACTION_MAIN, null);
 mainIntent.addCategory(Intent.CATEGORY_LAUNCHER);
 List<ResolveInfo> pkgAppsList = context.getPackageManager().queryIntentActivities( mainIntent, 0);
Sreyas
  • 744
  • 1
  • 7
  • 25