PackageManager Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Manages the software available to a user.
public ref class PackageManager sealed
/// [Windows.Foundation.Metadata.Activatable(65536, Windows.Foundation.UniversalApiContract)]
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class PackageManager final
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
/// [Windows.Foundation.Metadata.Activatable(65536, "Windows.Foundation.UniversalApiContract")]
class PackageManager final
[Windows.Foundation.Metadata.Activatable(65536, typeof(Windows.Foundation.UniversalApiContract))]
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class PackageManager
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
[Windows.Foundation.Metadata.Activatable(65536, "Windows.Foundation.UniversalApiContract")]
public sealed class PackageManager
Public NotInheritable Class PackageManager
- Inheritance
- Attributes
Windows requirements
Device family |
Windows 10 (introduced in 10.0.10240.0)
|
API contract |
Windows.Foundation.UniversalApiContract (introduced in v1.0)
|
Remarks
Version history
Windows version | SDK version | Value added |
---|---|---|
1607 | 14393 | GetPackageVolumesAsync |
1703 | 15063 | AddPackageAsync(Uri,IEnumerable<Uri>,DeploymentOptions,PackageVolume,IEnumerable,IEnumerable<Uri>) |
1703 | 15063 | DebugSettings |
1703 | 15063 | RegisterPackageByFamilyNameAsync |
1703 | 15063 | StagePackageAsync(Uri,IEnumerable<Uri>,DeploymentOptions,PackageVolume,IEnumerable,IEnumerable<Uri>) |
1709 | 16299 | AddPackageAsync(Uri,IEnumerable<Uri>,DeploymentOptions,PackageVolume,IEnumerable,IEnumerable<Uri>,IEnumerable<Uri>) |
1709 | 16299 | AddPackageByAppInstallerFileAsync |
1709 | 16299 | ProvisionPackageForAllUsersAsync |
1709 | 16299 | RequestAddPackageAsync(Uri,IEnumerable<Uri>,DeploymentOptions,PackageVolume,IEnumerable,IEnumerable<Uri>) |
1709 | 16299 | RequestAddPackageByAppInstallerFileAsync |
1709 | 16299 | StagePackageAsync(Uri,IEnumerable<Uri>,DeploymentOptions,PackageVolume,IEnumerable,IEnumerable<Uri>,IEnumerable<<Uri>) |
1803 | 17134 | RequestAddPackageAsync(Uri,IEnumerable<Uri>,DeploymentOptions,PackageVolume,IEnumerable,IEnumerable<Uri>,IEnumerable<Uri>) |
1809 | 17763 | DeprovisionPackageForAllUsersAsync |
2004 | 19041 | AddPackageByUriAsync |
2004 | 19041 | FindProvisionedPackages |
2004 | 19041 | GetPackageStubPreference |
2004 | 19041 | RegisterPackageByUriAsync |
2004 | 19041 | RegisterPackagesByFullNameAsync |
2004 | 19041 | SetPackageStubPreference |
2004 | 19041 | StagePackageByUriAsync |
Constructors
PackageManager() |
Creates and initializes a new instance of the object. |
Properties
DebugSettings |
Get the debugging settings for Package deployment. |
Methods
AddPackageAsync(Uri, IIterable<Uri>, DeploymentOptions, PackageVolume, IIterable<String>, IIterable<Uri>, IIterable<Uri>) |
Adds a Package (the main package) and its dependency packages for the current user, using the specified deployment options. |
AddPackageAsync(Uri, IIterable<Uri>, DeploymentOptions, PackageVolume, IIterable<String>, IIterable<Uri>) |
Adds a Package and its dependency packages to the specified volume for the current user, using the specified deployment options. |
AddPackageAsync(Uri, IIterable<Uri>, DeploymentOptions, PackageVolume) |
Adds a Package (the main package) and its dependency packages to the specified volume for the current user, using the specified deployment options. |
AddPackageAsync(Uri, IIterable<Uri>, DeploymentOptions) |
Adds a Package (the main package) and its dependency packages for the current user, using the specified deployment options. |
AddPackageByAppInstallerFileAsync(Uri, AddPackageByAppInstallerOptions, PackageVolume) |
Allows single or multiple app Packages to be installed with an .appinstaller file. |
AddPackageByUriAsync(Uri, AddPackageOptions) |
Adds a Package (the main package) and any additional dependency packages, for the current user, using the specified deployment options. |
AddPackageVolumeAsync(String) |
Creates a new volume. The caller must be a member of the administrators group. |
CleanupPackageForUserAsync(String, String) |
Cleans up a specified Package for a specified user. Used to cleanup packages installed for a user after their user profile is deleted. |
ClearPackageStatus(String, PackageStatus) |
Clears the status of a Package. |
DeprovisionPackageForAllUsersAsync(String) |
Deprovisions an app Package so new users on the device will no longer have the app automatically installed. |
FindPackage(String) |
Retrieves information about the specified Package installed for any user. |
FindPackageForUser(String, String) |
Retrieves information about a specific Package installed for a specific user or for all users. |
FindPackages() |
Retrieves information about a specified family of Packages installed across all users. |
FindPackages(String, String) |
Finds all installed Packages with the specified name and publisher. |
FindPackages(String) |
Retrieves information about a specified family of Packages installed across all users. |
FindPackagesForUser(String, String, String) |
Retrieves information about all Packages with the specified package name and publisher name, installed for a specific user. |
FindPackagesForUser(String, String) |
Retrieves information about a specified family of Packages installed for a specific user. |
FindPackagesForUser(String) |
Finds all Packages installed for the specified user. |
FindPackagesForUserWithPackageTypes(String, PackageTypes) |
Finds packages of specific types that are installed for the specified user. |
FindPackagesForUserWithPackageTypes(String, String, PackageTypes) |
Retrieves information about a specified family of Packages and of specific types that are installed for the specified user. |
FindPackagesForUserWithPackageTypes(String, String, String, PackageTypes) |
Retrieves information about Packages of specific types with the specified package name and publisher name, installed for a specific user. |
FindPackagesWithPackageTypes(PackageTypes) |
Retrieves information about specific Package types that are installed across all users. |
FindPackagesWithPackageTypes(String, PackageTypes) |
Retrieves information about a specified family of Packages and specific package types that are installed across all users. |
FindPackagesWithPackageTypes(String, String, PackageTypes) |
Finds all installed Packages of specific types with the specified name and publisher. |
FindPackageVolume(String) |
Gets the specified volume. |
FindPackageVolumes() |
Gets all the known volumes, regardless of their current state. |
FindProvisionedPackages() |
Gets the list of all installed Packages on the device. |
FindUsers(String) |
Finds the users who have installed the specified Package. |
GetDefaultPackageVolume() |
Gets the default Package volume, which is the target of deployment operations such as the AddPackageAsync method. |
GetPackageStubPreference(String) |
Gets a value that indicates whether the specified app Package currently prefers to run as a full app or a stub app. |
GetPackageVolumesAsync() |
Gets the Package volumes on the device. |
IsPackageRemovalPending(String) | |
IsPackageRemovalPendingByUri(Uri) | |
IsPackageRemovalPendingByUriForUser(Uri, String) | |
IsPackageRemovalPendingForUser(String, String) | |
MovePackageToVolumeAsync(String, DeploymentOptions, PackageVolume) |
Moves the specified Package to the specified volume using the specified deployment options. |
ProvisionPackageForAllUsersAsync(String, PackageAllUserProvisioningOptions) |
Enables an app Package to be installed for all users on a device, including options for specifying additional optional packages to be installed. |
ProvisionPackageForAllUsersAsync(String) |
Enables an app Package to be installed for all users on a device. |
RegisterPackageAsync(Uri, IIterable<Uri>, DeploymentOptions, PackageVolume) |
Registers a Package (the main package) and its dependency packages on the specified volume for the current user, using the specified deployment options. |
RegisterPackageAsync(Uri, IIterable<Uri>, DeploymentOptions) |
Registers a Package (the main package) and its dependency packages for the current user, using the specified deployment options. |
RegisterPackageByFamilyNameAsync(String, IIterable<String>, DeploymentOptions, PackageVolume, IIterable<String>) |
Registers a Package (the main package) by its family name and its dependency packages for the current user. |
RegisterPackageByFullNameAsync(String, IIterable<String>, DeploymentOptions) |
Registers a Package (the main package) by its full name and its dependency packages for the current user. |
RegisterPackageByUriAsync(Uri, RegisterPackageOptions) |
Registers a Package (the main package) and its dependency packages for the current user, using the specified deployment options. |
RegisterPackagesByFullNameAsync(IIterable<String>, RegisterPackageOptions) |
Registers the specified Packages by their full name for the current user. |
RemovePackageAsync(String, RemovalOptions) |
Removes a Package for the current user asynchronously and receives progress and status messages on the removal operation. Dependency packages are also removed for the user if no other packages installed for the user depend on them. |
RemovePackageAsync(String) |
Removes a Package for the current user asynchronously and receives progress and status messages on the removal operation. Dependency packages are also removed for the user if no other packages installed for the user depend on them. |
RemovePackageByUriAsync(Uri, RemovePackageOptions) | |
RemovePackageVolumeAsync(PackageVolume) |
Removes the specified volume. |
RequestAddPackageAsync(Uri, IIterable<Uri>, DeploymentOptions, PackageVolume, IIterable<String>, IIterable<Uri>, IIterable<Uri>) |
Requests a SmartScreen check and user verification before installing the app Package(s). This method provides a packageUrisToInstall overload to specify external packages to be staged and registered. |
RequestAddPackageAsync(Uri, IIterable<Uri>, DeploymentOptions, PackageVolume, IIterable<String>, IIterable<Uri>) |
Requests a SmartScreen check and user verification before installing the app Package(s). |
RequestAddPackageByAppInstallerFileAsync(Uri, AddPackageByAppInstallerOptions, PackageVolume) |
Allows single or multiple app Packages to be installed with an .appinstaller file. This will perform a SmartScreen filter and user verification before installing the app package(s). |
SetDefaultPackageVolume(PackageVolume) |
Sets the default Package volume, which is the target of deployment operations such as the AddPackageAsync method. |
SetPackageState(String, PackageState) |
Sets the state of a Package, for example, to usable, tampered with, and so on. |
SetPackageStatus(String, PackageStatus) |
Sets the status of the specified Package. |
SetPackageStubPreference(String, PackageStubPreference) |
Sets a value that indicates whether the specified app Package currently prefers to run as a full app or a stub app. |
SetPackageVolumeOfflineAsync(PackageVolume) |
Sets the specified volume to an offline state. The caller must be a member of the administrators group. |
SetPackageVolumeOnlineAsync(PackageVolume) |
Sets the specified volume to an online state. The caller must be a member of the administrators group. |
StagePackageAsync(Uri, IIterable<Uri>, DeploymentOptions, PackageVolume, IIterable<String>, IIterable<Uri>, IIterable<Uri>) |
Stages a Package to the system without registering it. |
StagePackageAsync(Uri, IIterable<Uri>, DeploymentOptions, PackageVolume, IIterable<String>, IIterable<Uri>) |
Stages a Package to the system without registering it. |
StagePackageAsync(Uri, IIterable<Uri>, DeploymentOptions, PackageVolume) |
Stages a Package to the system without registering it. |
StagePackageAsync(Uri, IIterable<Uri>, DeploymentOptions) |
Stages a Package to the system without registering it. |
StagePackageAsync(Uri, IIterable<Uri>) |
Stages a Package to the system without registering it. |
StagePackageByUriAsync(Uri, StagePackageOptions) |
Stages a Package to the system without registering it, using the specified deployment options. |
StageUserDataAsync(String, DeploymentOptions) |
Stages a Package's roaming data to the system without registering the package. Call this method after staging the package but before registering the package for a particular user. |
StageUserDataAsync(String) |
Stages a Package's roaming data to the system without registering the package. Call this method after staging the package but before registering the package for a particular user. |
UpdatePackageAsync(Uri, IIterable<Uri>, DeploymentOptions) |
Updates an installed Package or its dependency packages for the current user. |