Commit f6fd79a3 authored by Rémi Bernon's avatar Rémi Bernon Committed by Alexandre Julliard

include: Add Windows.Management.Deployment.PackageManager runtimeclass definition.

parent cdf3355d
......@@ -25,14 +25,61 @@ import "windows.applicationmodel.idl";
namespace Windows.Management.Deployment {
typedef enum DeploymentOptions DeploymentOptions;
typedef enum DeploymentProgressState DeploymentProgressState;
typedef enum PackageInstallState PackageInstallState;
typedef enum PackageState PackageState;
typedef struct DeploymentProgress DeploymentProgress;
interface IDeploymentResult;
interface IPackageManager;
interface IPackageUserInformation;
runtimeclass DeploymentResult;
runtimeclass PackageManager;
runtimeclass PackageUserInformation;
declare {
interface Windows.Foundation.Collections.IIterable<Windows.Foundation.Uri *>;
interface Windows.Foundation.Collections.IIterator<Windows.Foundation.Uri *>;
interface Windows.Foundation.Collections.IIterable<Windows.ApplicationModel.Package *>;
interface Windows.Foundation.Collections.IIterator<Windows.ApplicationModel.Package *>;
interface Windows.Foundation.Collections.IIterable<Windows.Management.Deployment.PackageUserInformation *>;
interface Windows.Foundation.Collections.IIterator<Windows.Management.Deployment.PackageUserInformation *>;
interface Windows.Foundation.IAsyncOperationWithProgress<Windows.Management.Deployment.DeploymentResult *, Windows.Management.Deployment.DeploymentProgress>;
interface Windows.Foundation.AsyncOperationProgressHandler<Windows.Management.Deployment.DeploymentResult *, Windows.Management.Deployment.DeploymentProgress>;
interface Windows.Foundation.AsyncOperationWithProgressCompletedHandler<Windows.Management.Deployment.DeploymentResult *, Windows.Management.Deployment.DeploymentProgress>;
}
[contract(Windows.Foundation.UniversalApiContract, 1.0)]
[flags]
enum DeploymentOptions
{
None = 0x0,
ForceApplicationShutdown = 0x1,
DevelopmentMode = 0x2,
[contract(Windows.Foundation.UniversalApiContract, 1.0)]
InstallAllResources = 0x20,
[contract(Windows.Foundation.UniversalApiContract, 1.0)]
ForceTargetApplicationShutdown = 0x40,
[contract(Windows.Foundation.UniversalApiContract, 4.0)]
RequiredContentGroupOnly = 0x100,
[contract(Windows.Foundation.UniversalApiContract, 7.0)]
ForceUpdateFromAnyVersion = 0x40000,
[contract(Windows.Foundation.UniversalApiContract, 10.0)]
RetainFilesOnFailure = 0x200000,
[contract(Windows.Foundation.UniversalApiContract, 10.0)]
StageInPlace = 0x400000,
};
[contract(Windows.Foundation.UniversalApiContract, 1.0)]
enum DeploymentProgressState
{
Queued = 0,
Processing = 1,
};
[contract(Windows.Foundation.UniversalApiContract, 1.0)]
enum PackageInstallState
{
......@@ -43,6 +90,22 @@ namespace Windows.Management.Deployment {
Paused = 6,
};
[contract(Windows.Foundation.UniversalApiContract, 1.0)]
enum PackageState
{
Normal = 0,
LicenseInvalid = 1,
Modified = 2,
Tampered = 3,
};
[contract(Windows.Foundation.UniversalApiContract, 1.0)]
struct DeploymentProgress
{
Windows.Management.Deployment.DeploymentProgressState state;
UINT32 percentage;
};
[
contract(Windows.Foundation.UniversalApiContract, 1.0),
exclusiveto(Windows.Management.Deployment.DeploymentResult),
......@@ -57,6 +120,45 @@ namespace Windows.Management.Deployment {
[
contract(Windows.Foundation.UniversalApiContract, 1.0),
exclusiveto(Windows.Management.Deployment.PackageManager),
uuid(9a7d4b65-5e8f-4fc7-a2e5-7f6925cb8b53)
]
interface IPackageManager : IInspectable
{
[overload("AddPackageAsync")]
HRESULT AddPackageAsync([in] Windows.Foundation.Uri *uri, [in] Windows.Foundation.Collections.IIterable<Windows.Foundation.Uri *> *dependencies, [in] Windows.Management.Deployment.DeploymentOptions options,
[out, retval] Windows.Foundation.IAsyncOperationWithProgress<Windows.Management.Deployment.DeploymentResult *, Windows.Management.Deployment.DeploymentProgress> **operation);
HRESULT UpdatePackageAsync([in] Windows.Foundation.Uri *uri, [in] Windows.Foundation.Collections.IIterable<Windows.Foundation.Uri *> *dependencies, [in] Windows.Management.Deployment.DeploymentOptions options,
[out, retval] Windows.Foundation.IAsyncOperationWithProgress<Windows.Management.Deployment.DeploymentResult *, Windows.Management.Deployment.DeploymentProgress> **operation);
HRESULT RemovePackageAsync([in] HSTRING name, [out, retval] Windows.Foundation.IAsyncOperationWithProgress<Windows.Management.Deployment.DeploymentResult *, Windows.Management.Deployment.DeploymentProgress> **operation);
HRESULT StagePackageAsync([in] Windows.Foundation.Uri *uri, [in] Windows.Foundation.Collections.IIterable<Windows.Foundation.Uri *> *dependencies,
[out, retval] Windows.Foundation.IAsyncOperationWithProgress<Windows.Management.Deployment.DeploymentResult *, Windows.Management.Deployment.DeploymentProgress> **operation);
[overload("RegisterPackageAsync")]
HRESULT RegisterPackageAsync([in] Windows.Foundation.Uri* uri, [in] Windows.Foundation.Collections.IIterable<Windows.Foundation.Uri *> *dependencies, [in] Windows.Management.Deployment.DeploymentOptions options,
[out, retval] Windows.Foundation.IAsyncOperationWithProgress<Windows.Management.Deployment.DeploymentResult *, Windows.Management.Deployment.DeploymentProgress> **operation);
[overload("FindPackages")]
HRESULT FindPackages([out, retval] Windows.Foundation.Collections.IIterable<Windows.ApplicationModel.Package *> **packages);
[overload("FindPackagesForUser")]
HRESULT FindPackagesByUserSecurityId([in] HSTRING sid, [out, retval] Windows.Foundation.Collections.IIterable<Windows.ApplicationModel.Package *> **packages);
[overload("FindPackages")]
HRESULT FindPackagesByNamePublisher([in] HSTRING name, [in] HSTRING publisher, [out, retval] Windows.Foundation.Collections.IIterable<Windows.ApplicationModel.Package *> **packages);
[overload("FindPackagesForUser")]
HRESULT FindPackagesByUserSecurityIdNamePublisher([in] HSTRING sid, [in] HSTRING name, [in] HSTRING publisher, [out, retval] Windows.Foundation.Collections.IIterable<Windows.ApplicationModel.Package *> **packages);
HRESULT FindUsers([in] HSTRING name, [out, retval] Windows.Foundation.Collections.IIterable<Windows.Management.Deployment.PackageUserInformation *> **users);
HRESULT SetPackageState([in] HSTRING name, [in] Windows.Management.Deployment.PackageState state);
[overload("FindPackage")]
HRESULT FindPackageByPackageFullName([in] HSTRING name, [out, retval] Windows.ApplicationModel.Package **package);
HRESULT CleanupPackageForUserAsync([in] HSTRING name, [in] HSTRING sid, [out, retval] Windows.Foundation.IAsyncOperationWithProgress<Windows.Management.Deployment.DeploymentResult *, Windows.Management.Deployment.DeploymentProgress> **operation);
[overload("FindPackages")]
HRESULT FindPackagesByPackageFamilyName([in] HSTRING family_name, [out, retval] Windows.Foundation.Collections.IIterable<Windows.ApplicationModel.Package *> **packages);
[overload("FindPackagesForUser")]
HRESULT FindPackagesByUserSecurityIdPackageFamilyName([in] HSTRING sid, [in] HSTRING family_name, [out, retval] Windows.Foundation.Collections.IIterable<Windows.ApplicationModel.Package *> **packages);
[overload("FindPackageForUser")]
HRESULT FindPackageByUserSecurityIdPackageFullName([in] HSTRING sid, [in] HSTRING name, [out, retval] Windows.ApplicationModel.Package **package);
}
[
contract(Windows.Foundation.UniversalApiContract, 1.0),
exclusiveto(Windows.Management.Deployment.PackageUserInformation),
uuid(f6383423-fa09-4cbc-9055-15ca275e2e7e)
]
......@@ -77,6 +179,25 @@ namespace Windows.Management.Deployment {
}
[
activatable(Windows.Foundation.UniversalApiContract, 1.0),
contract(Windows.Foundation.UniversalApiContract, 1.0),
marshaling_behavior(agile),
threading(both)
]
runtimeclass PackageManager
{
[default] interface Windows.Management.Deployment.IPackageManager;
[contract(Windows.Foundation.UniversalApiContract, 1.0)] interface Windows.Management.Deployment.IPackageManager2;
[contract(Windows.Foundation.UniversalApiContract, 1.0)] interface Windows.Management.Deployment.IPackageManager3;
[contract(Windows.Foundation.UniversalApiContract, 3.0)] interface Windows.Management.Deployment.IPackageManager4;
[contract(Windows.Foundation.UniversalApiContract, 4.0)] interface Windows.Management.Deployment.IPackageManager5;
[contract(Windows.Foundation.UniversalApiContract, 5.0)] interface Windows.Management.Deployment.IPackageManager6;
[contract(Windows.Foundation.UniversalApiContract, 6.0)] interface Windows.Management.Deployment.IPackageManager7;
[contract(Windows.Foundation.UniversalApiContract, 7.0)] interface Windows.Management.Deployment.IPackageManager8;
[contract(Windows.Foundation.UniversalApiContract, 10.0)] interface Windows.Management.Deployment.IPackageManager9;
}
[
contract(Windows.Foundation.UniversalApiContract, 1.0),
marshaling_behavior(agile)
]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment