PackageManager.GetInstalledPackages(PackageInfoFlags) Method

Definition

Return a List of all packages that are installed for the current user.

[Android.Runtime.Register("getInstalledPackages", "(I)Ljava/util/List;", "GetGetInstalledPackages_IHandler")]
public abstract System.Collections.Generic.IList<Android.Content.PM.PackageInfo> GetInstalledPackages (Android.Content.PM.PackageInfoFlags flags);
[<Android.Runtime.Register("getInstalledPackages", "(I)Ljava/util/List;", "GetGetInstalledPackages_IHandler")>]
abstract member GetInstalledPackages : Android.Content.PM.PackageInfoFlags -> System.Collections.Generic.IList<Android.Content.PM.PackageInfo>

Parameters

flags
PackageInfoFlags

Additional option flags to modify the data returned.

Returns

IList<PackageInfo>

A List of PackageInfo objects, one for each installed package, containing information about the package. In the unlikely case there are no installed packages, an empty list is returned. If flag MATCH_UNINSTALLED_PACKAGES is set, the package information is retrieved from the list of uninstalled applications (which includes installed applications as well as applications with data directory i.e. applications which had been deleted with DELETE_KEEP_DATA flag set).

Attributes

Remarks

Java documentation for android.content.pm.PackageManager.getInstalledPackages(int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to