Update WinRT to new version 2.0.250303.1

PiperOrigin-RevId: 781075193
This commit is contained in:
Guogang Li
2025-07-09 08:58:00 -07:00
committed by Copybara-Service
parent 5e558cffc4
commit 8f14bd10fc
1395 changed files with 498490 additions and 61973 deletions
@@ -1,11 +1,11 @@
// WARNING: Please don't edit this file. It was generated by C++/WinRT v2.0.220531.1
// WARNING: Please don't edit this file. It was generated by C++/WinRT v2.0.250303.1
#pragma once
#ifndef WINRT_Windows_System_Update_H
#define WINRT_Windows_System_Update_H
#include "winrt/base.h"
static_assert(winrt::check_version(CPPWINRT_VERSION, "2.0.220531.1"), "Mismatched C++/WinRT headers.");
#define CPPWINRT_VERSION "2.0.220531.1"
static_assert(winrt::check_version(CPPWINRT_VERSION, "2.0.250303.1"), "Mismatched C++/WinRT headers.");
#define CPPWINRT_VERSION "2.0.250303.1"
#include "winrt/Windows.System.h"
#include "winrt/impl/Windows.Foundation.2.h"
#include "winrt/impl/Windows.Foundation.Collections.2.h"
@@ -15,85 +15,253 @@ namespace winrt::impl
template <typename D> auto consume_Windows_System_Update_ISystemUpdateItem<D>::State() const
{
winrt::Windows::System::Update::SystemUpdateItemState value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateItem)->get_State(reinterpret_cast<int32_t*>(&value)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateItem>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateItem, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_State(reinterpret_cast<int32_t*>(&value)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)this;
check_hresult(_winrt_abi_type->get_State(reinterpret_cast<int32_t*>(&value)));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateItem<D>::Title() const
{
void* value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateItem)->get_Title(&value));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateItem>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateItem, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_Title(&value));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)this;
check_hresult(_winrt_abi_type->get_Title(&value));
}
return hstring{ value, take_ownership_from_abi };
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateItem<D>::Description() const
{
void* value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateItem)->get_Description(&value));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateItem>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateItem, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_Description(&value));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)this;
check_hresult(_winrt_abi_type->get_Description(&value));
}
return hstring{ value, take_ownership_from_abi };
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateItem<D>::Id() const
{
void* value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateItem)->get_Id(&value));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateItem>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateItem, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_Id(&value));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)this;
check_hresult(_winrt_abi_type->get_Id(&value));
}
return hstring{ value, take_ownership_from_abi };
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateItem<D>::Revision() const
{
uint32_t value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateItem)->get_Revision(&value));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateItem>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateItem, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_Revision(&value));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)this;
check_hresult(_winrt_abi_type->get_Revision(&value));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateItem<D>::DownloadProgress() const
{
double value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateItem)->get_DownloadProgress(&value));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateItem>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateItem, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_DownloadProgress(&value));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)this;
check_hresult(_winrt_abi_type->get_DownloadProgress(&value));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateItem<D>::InstallProgress() const
{
double value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateItem)->get_InstallProgress(&value));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateItem>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateItem, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_InstallProgress(&value));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)this;
check_hresult(_winrt_abi_type->get_InstallProgress(&value));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateItem<D>::ExtendedError() const
{
winrt::hresult value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateItem)->get_ExtendedError(put_abi(value)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateItem>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateItem, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateItem>**)this;
check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value)));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateLastErrorInfo<D>::State() const
{
winrt::Windows::System::Update::SystemUpdateManagerState value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateLastErrorInfo)->get_State(reinterpret_cast<int32_t*>(&value)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateLastErrorInfo>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateLastErrorInfo, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateLastErrorInfo>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_State(reinterpret_cast<int32_t*>(&value)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateLastErrorInfo>**)this;
check_hresult(_winrt_abi_type->get_State(reinterpret_cast<int32_t*>(&value)));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateLastErrorInfo<D>::ExtendedError() const
{
winrt::hresult value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateLastErrorInfo)->get_ExtendedError(put_abi(value)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateLastErrorInfo>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateLastErrorInfo, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateLastErrorInfo>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateLastErrorInfo>**)this;
check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value)));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateLastErrorInfo<D>::IsInteractive() const
{
bool value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateLastErrorInfo)->get_IsInteractive(&value));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateLastErrorInfo>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateLastErrorInfo, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateLastErrorInfo>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_IsInteractive(&value));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateLastErrorInfo>**)this;
check_hresult(_winrt_abi_type->get_IsInteractive(&value));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::IsSupported() const
{
bool result{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->IsSupported(&result));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->IsSupported(&result));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->IsSupported(&result));
}
return result;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::State() const
{
winrt::Windows::System::Update::SystemUpdateManagerState value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->get_State(reinterpret_cast<int32_t*>(&value)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_State(reinterpret_cast<int32_t*>(&value)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->get_State(reinterpret_cast<int32_t*>(&value)));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::StateChanged(winrt::Windows::Foundation::EventHandler<winrt::Windows::Foundation::IInspectable> const& handler) const
{
winrt::event_token token{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->add_StateChanged(*(void**)(&handler), put_abi(token)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->add_StateChanged(*(void**)(&handler), put_abi(token)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->add_StateChanged(*(void**)(&handler), put_abi(token)));
}
return token;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::StateChanged(auto_revoke_t, winrt::Windows::Foundation::EventHandler<winrt::Windows::Foundation::IInspectable> const& handler) const
@@ -102,121 +270,373 @@ namespace winrt::impl
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::StateChanged(winrt::event_token const& token) const noexcept
{
WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->remove_StateChanged(impl::bind_in(token));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
_winrt_abi_type->remove_StateChanged(impl::bind_in(token));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
_winrt_abi_type->remove_StateChanged(impl::bind_in(token));
}
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::DownloadProgress() const
{
double value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->get_DownloadProgress(&value));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_DownloadProgress(&value));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->get_DownloadProgress(&value));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::InstallProgress() const
{
double value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->get_InstallProgress(&value));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_InstallProgress(&value));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->get_InstallProgress(&value));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::UserActiveHoursStart() const
{
winrt::Windows::Foundation::TimeSpan value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->get_UserActiveHoursStart(put_abi(value)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_UserActiveHoursStart(put_abi(value)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->get_UserActiveHoursStart(put_abi(value)));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::UserActiveHoursEnd() const
{
winrt::Windows::Foundation::TimeSpan value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->get_UserActiveHoursEnd(put_abi(value)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_UserActiveHoursEnd(put_abi(value)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->get_UserActiveHoursEnd(put_abi(value)));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::UserActiveHoursMax() const
{
int32_t value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->get_UserActiveHoursMax(&value));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_UserActiveHoursMax(&value));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->get_UserActiveHoursMax(&value));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::TrySetUserActiveHours(winrt::Windows::Foundation::TimeSpan const& start, winrt::Windows::Foundation::TimeSpan const& end) const
{
bool result{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->TrySetUserActiveHours(impl::bind_in(start), impl::bind_in(end), &result));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->TrySetUserActiveHours(impl::bind_in(start), impl::bind_in(end), &result));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->TrySetUserActiveHours(impl::bind_in(start), impl::bind_in(end), &result));
}
return result;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::LastUpdateCheckTime() const
{
winrt::Windows::Foundation::DateTime value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->get_LastUpdateCheckTime(put_abi(value)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_LastUpdateCheckTime(put_abi(value)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->get_LastUpdateCheckTime(put_abi(value)));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::LastUpdateInstallTime() const
{
winrt::Windows::Foundation::DateTime value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->get_LastUpdateInstallTime(put_abi(value)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_LastUpdateInstallTime(put_abi(value)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->get_LastUpdateInstallTime(put_abi(value)));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::LastErrorInfo() const
{
void* value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->get_LastErrorInfo(&value));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_LastErrorInfo(&value));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->get_LastErrorInfo(&value));
}
return winrt::Windows::System::Update::SystemUpdateLastErrorInfo{ value, take_ownership_from_abi };
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::GetAutomaticRebootBlockIds() const
{
void* result{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->GetAutomaticRebootBlockIds(&result));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->GetAutomaticRebootBlockIds(&result));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->GetAutomaticRebootBlockIds(&result));
}
return winrt::Windows::Foundation::Collections::IVectorView<hstring>{ result, take_ownership_from_abi };
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::BlockAutomaticRebootAsync(param::hstring const& lockId) const
{
void* operation{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->BlockAutomaticRebootAsync(*(void**)(&lockId), &operation));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->BlockAutomaticRebootAsync(*(void**)(&lockId), &operation));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->BlockAutomaticRebootAsync(*(void**)(&lockId), &operation));
}
return winrt::Windows::Foundation::IAsyncOperation<bool>{ operation, take_ownership_from_abi };
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::UnblockAutomaticRebootAsync(param::hstring const& lockId) const
{
void* operation{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->UnblockAutomaticRebootAsync(*(void**)(&lockId), &operation));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->UnblockAutomaticRebootAsync(*(void**)(&lockId), &operation));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->UnblockAutomaticRebootAsync(*(void**)(&lockId), &operation));
}
return winrt::Windows::Foundation::IAsyncOperation<bool>{ operation, take_ownership_from_abi };
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::ExtendedError() const
{
winrt::hresult value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->get_ExtendedError(put_abi(value)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value)));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::GetUpdateItems() const
{
void* result{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->GetUpdateItems(&result));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->GetUpdateItems(&result));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->GetUpdateItems(&result));
}
return winrt::Windows::Foundation::Collections::IVectorView<winrt::Windows::System::Update::SystemUpdateItem>{ result, take_ownership_from_abi };
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::AttentionRequiredReason() const
{
winrt::Windows::System::Update::SystemUpdateAttentionRequiredReason value{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->get_AttentionRequiredReason(reinterpret_cast<int32_t*>(&value)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_AttentionRequiredReason(reinterpret_cast<int32_t*>(&value)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->get_AttentionRequiredReason(reinterpret_cast<int32_t*>(&value)));
}
return value;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::SetFlightRing(param::hstring const& flightRing) const
{
bool result{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->SetFlightRing(*(void**)(&flightRing), &result));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->SetFlightRing(*(void**)(&flightRing), &result));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->SetFlightRing(*(void**)(&flightRing), &result));
}
return result;
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::GetFlightRing() const
{
void* result{};
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->GetFlightRing(&result));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->GetFlightRing(&result));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->GetFlightRing(&result));
}
return hstring{ result, take_ownership_from_abi };
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::StartInstall(winrt::Windows::System::Update::SystemUpdateStartInstallAction const& action) const
{
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->StartInstall(static_cast<int32_t>(action)));
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->StartInstall(static_cast<int32_t>(action)));
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->StartInstall(static_cast<int32_t>(action)));
}
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::RebootToCompleteInstall() const
{
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->RebootToCompleteInstall());
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->RebootToCompleteInstall());
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->RebootToCompleteInstall());
}
}
template <typename D> auto consume_Windows_System_Update_ISystemUpdateManagerStatics<D>::StartCancelUpdates() const
{
check_hresult(WINRT_IMPL_SHIM(winrt::Windows::System::Update::ISystemUpdateManagerStatics)->StartCancelUpdates());
if constexpr (!std::is_same_v<D, winrt::Windows::System::Update::ISystemUpdateManagerStatics>)
{
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<winrt::Windows::System::Update::ISystemUpdateManagerStatics, D const*>(static_cast<D const*>(this), _winrt_cast_result_code);
check_hresult(_winrt_cast_result_code);
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->StartCancelUpdates());
}
else
{
auto const _winrt_abi_type = *(abi_t<winrt::Windows::System::Update::ISystemUpdateManagerStatics>**)this;
check_hresult(_winrt_abi_type->StartCancelUpdates());
}
}
#ifndef WINRT_LEAN_AND_MEAN
template <typename D>