PackageVolume Class

Definition

Represents a Package storage volume.

public ref class PackageVolume sealed
/// [Windows.Foundation.Metadata.ContractVersion(Microsoft.Windows.Management.Deployment.PackageDeploymentContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class PackageVolume final
[Windows.Foundation.Metadata.ContractVersion(typeof(Microsoft.Windows.Management.Deployment.PackageDeploymentContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class PackageVolume
Public NotInheritable Class PackageVolume
Inheritance
Object Platform::Object IInspectable PackageVolume
Attributes

Remarks

Packages are typically installed to a PackageVolume. For example, C:\Program Files\WindowsApps is the default package volume on a new Windows system. However, RegisterPackageOptions.DeveloperMode, and AddPackageOptions.StageInPlace, and other options, can alter the typical behavior and install packages to a non-package-volume location.

Properties

IsAppxInstallSupported

Gets a value that indicates whether or not APPX installing is supported.

IsFullTrustPackageSupported

Gets a value that indicates whether or not full-trust packages are supported.

IsSystemVolume

Gets a value indicating whether or not the volume is an internal system volume mapped to the %SYSTEMDRIVER% environment variable.

MountPoint

Gets the path of the last known volume mount point.

Name

Gets the name of the package volume. A volume's name is the volume's media ID; so you can think of "volume name" as "volume media ID". Also see System.VolumeId.

PackageStorePath

Gets the absolute path for the package store on the volume.

SupportsHardLinks

Gets a value that indicates whether or not the volume supports the creation of hard links in its file system.

Methods

FindPackageVolumeByName(String)

Retrieves the specified volume.

FindPackageVolumeByPath(String)

Retrieves the specified volume.

FindPackageVolumes()

Retrieves all the known volumes, regardless of their current state.

IsRepairNeeded()

Determines whether or not a call to PackageVolume.Repair is needed. IsRepairNeeded doesn't require admin privilege.

Repair()

Attempts to detect and correct invalidated package volume tracking information (and other similar conditions). Repair requires admin privilege.

Applies to

See also