Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WinGet Source COM Api #4813

Draft
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

Madhusudhan-MSFT
Copy link
Contributor

@Madhusudhan-MSFT Madhusudhan-MSFT commented Sep 16, 2024

Draft implementation of WinGet Source COM API for review.


Microsoft Reviewers: Open in CodeFlow

- Update IDL for new runtime classes and methods.
- Add files and classes for package catalog operations (add, remove, reset, update).
- Update `PackageManager` with async methods for catalog operations.

[Compiles successfully]
Introduced new interfaces in the `Microsoft.Management.Deployment`
namespace within the `PackageManager.idl` file. Added interfaces
for handling collections of `AddPackageCatalogOptions`,
`AddPackageCatalogResult`, `RemovePackageCatalogResult`,
`ResetPackageCatalogResult`, and `UpdatePackageCatalogResult`.
- Update `Package.appxmanifest` with a new entry.
- Add a new entry in `Microsoft.Management.Deployment.InProc.dll.manifest`.
- Define new `constexpr CLSID` values for `AddPackageCatalogOptions` in `Factory.cpp`.
  - Update `s_nameCLSIDPairs` array to include `AddPackageCatalogOptions`.
- Add entry to type dictionary in ClassesDefinition.cs.
- Introduce CreateAddPackageCatalogOptions method in WinGetProjectionFactory.cs.
@Madhusudhan-MSFT Madhusudhan-MSFT changed the title win get source com api WinGet Source com api Sep 17, 2024
@Madhusudhan-MSFT Madhusudhan-MSFT changed the title WinGet Source com api WinGet Source COM Api Sep 17, 2024
…nager.idl

- Renamed `CatalogName` to `Name` and `m_catalogName` to `m_name` in `AddPackageCatalogOptions`.
- Removed `Arguments` property and its methods.
- Added new boolean property `Explicit` with getter and setter.

Updated `PackageManager.idl` to reflect these changes:
- Renamed `CatalogName` to `Name` with updated comments.
- Removed `Arguments` property.
- Added `Explicit` property with explanatory comments.
- Updated `RemovePackageCatalogAsync` description to use "catalog".
- Removed several `IVector` and `IVectorView` interfaces related to
  package catalog options and results.
…thods

- Simplified progress reporting for *CatalogPackageAsync operations in PackageManager by using a double type.
- Updated method signatures and removed related enums and structures in PackageManager.cpp, PackageManager.h, and PackageManager.idl.
- Introduce new async methods in `PackageCatalogReference` for
removing, resetting, and updating package catalogs.
- These methods are defined in `PackageCatalogReference.h` and implemented as placeholders in `PackageCatalogReference.cpp`.
- Remove corresponding methods from `PackageManager`, shifting responsibility to `PackageCatalogReference`.

Update `PackageManager.idl` to reflect these changes:
- Add enums and result classes for new operations.
- Include new async methods in `PackageCatalogReference`.
- Remove outdated methods from `PackageManager`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants