Files
nearby/internal/platform/implementation/windows/generated/winrt/Microsoft.Windows.Widgets.Notifications.h
T
2026-01-27 23:46:02 -08:00

1009 lines
45 KiB
C++

// WARNING: Please don't edit this file. It was generated by C++/WinRT
// v2.0.250303.1
#pragma once
#ifndef WINRT_Microsoft_Windows_Widgets_Notifications_H
#define WINRT_Microsoft_Windows_Widgets_Notifications_H
#include "winrt/base.h"
static_assert(winrt::check_version(CPPWINRT_VERSION, "2.0.250303.1"),
"Mismatched C++/WinRT headers.");
#define CPPWINRT_VERSION "2.0.250303.1"
#include "winrt/Microsoft.Windows.Widgets.h"
#include "winrt/impl/Microsoft.Windows.Widgets.Notifications.2.h"
#include "winrt/impl/Windows.Foundation.2.h"
namespace winrt::impl {
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<D>::Id()
const {
void* value{};
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_Id(&value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->get_Id(&value));
}
return hstring{value, take_ownership_from_abi};
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<D>::Id(
param::hstring const& value) const {
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->put_Id(*(void**)(&value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->put_Id(*(void**)(&value)));
}
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::PrimaryText() const {
void* value{};
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_PrimaryText(&value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->get_PrimaryText(&value));
}
return hstring{value, take_ownership_from_abi};
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::PrimaryText(param::hstring const& value) const {
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->put_PrimaryText(*(void**)(&value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->put_PrimaryText(*(void**)(&value)));
}
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::SecondaryText() const {
void* value{};
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_SecondaryText(&value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->get_SecondaryText(&value));
}
return hstring{value, take_ownership_from_abi};
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::SecondaryText(param::hstring const& value) const {
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->put_SecondaryText(*(void**)(&value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->put_SecondaryText(*(void**)(&value)));
}
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::LightModeIconUri() const {
void* value{};
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_LightModeIconUri(&value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->get_LightModeIconUri(&value));
}
return winrt::Windows::Foundation::Uri{value, take_ownership_from_abi};
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::LightModeIconUri(winrt::Windows::Foundation::Uri const& value) const {
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->put_LightModeIconUri(*(void**)(&value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->put_LightModeIconUri(*(void**)(&value)));
}
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::DarkModeIconUri() const {
void* value{};
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_DarkModeIconUri(&value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->get_DarkModeIconUri(&value));
}
return winrt::Windows::Foundation::Uri{value, take_ownership_from_abi};
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::DarkModeIconUri(winrt::Windows::Foundation::Uri const& value) const {
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->put_DarkModeIconUri(*(void**)(&value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->put_DarkModeIconUri(*(void**)(&value)));
}
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::PrimaryTextColor() const {
winrt::Microsoft::Windows::Widgets::Notifications::AnnouncementTextColor
value{};
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_PrimaryTextColor(
reinterpret_cast<int32_t*>(&value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->get_PrimaryTextColor(
reinterpret_cast<int32_t*>(&value)));
}
return value;
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::PrimaryTextColor(winrt::Microsoft::Windows::Widgets::Notifications::
AnnouncementTextColor const& value) const {
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(
_winrt_abi_type->put_PrimaryTextColor(static_cast<int32_t>(value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(
_winrt_abi_type->put_PrimaryTextColor(static_cast<int32_t>(value)));
}
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::SecondaryTextColor() const {
winrt::Microsoft::Windows::Widgets::Notifications::AnnouncementTextColor
value{};
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_SecondaryTextColor(
reinterpret_cast<int32_t*>(&value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->get_SecondaryTextColor(
reinterpret_cast<int32_t*>(&value)));
}
return value;
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::SecondaryTextColor(winrt::Microsoft::Windows::Widgets::Notifications::
AnnouncementTextColor const& value) const {
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(
_winrt_abi_type->put_SecondaryTextColor(static_cast<int32_t>(value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(
_winrt_abi_type->put_SecondaryTextColor(static_cast<int32_t>(value)));
}
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::CustomAccessibilityText() const {
void* value{};
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_CustomAccessibilityText(&value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->get_CustomAccessibilityText(&value));
}
return hstring{value, take_ownership_from_abi};
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::CustomAccessibilityText(param::hstring const& value) const {
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(
_winrt_abi_type->put_CustomAccessibilityText(*(void**)(&value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(
_winrt_abi_type->put_CustomAccessibilityText(*(void**)(&value)));
}
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::IsSecondaryTextSubtle() const {
bool value{};
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_IsSecondaryTextSubtle(&value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->get_IsSecondaryTextSubtle(&value));
}
return value;
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::IsSecondaryTextSubtle(bool value) const {
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->put_IsSecondaryTextSubtle(value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->put_IsSecondaryTextSubtle(value));
}
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::ShowBadgeIfUserNotEngaged() const {
bool value{};
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_ShowBadgeIfUserNotEngaged(&value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->get_ShowBadgeIfUserNotEngaged(&value));
}
return value;
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::ShowBadgeIfUserNotEngaged(bool value) const {
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->put_ShowBadgeIfUserNotEngaged(value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->put_ShowBadgeIfUserNotEngaged(value));
}
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::ExpirationTime() const {
winrt::Windows::Foundation::DateTime value{};
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_ExpirationTime(put_abi(value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->get_ExpirationTime(put_abi(value)));
}
return value;
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<D>::
ExpirationTime(winrt::Windows::Foundation::DateTime const& value) const {
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->put_ExpirationTime(impl::bind_in(value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->put_ExpirationTime(impl::bind_in(value)));
}
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::Duration() const {
winrt::Windows::Foundation::TimeSpan value{};
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_Duration(put_abi(value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->get_Duration(put_abi(value)));
}
return value;
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncement<
D>::Duration(winrt::Windows::Foundation::TimeSpan const& value) const {
if constexpr (!std::is_same_v<D, winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncement>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->put_Duration(impl::bind_in(value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement>**)this;
check_hresult(_winrt_abi_type->put_Duration(impl::bind_in(value)));
}
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncementFactory<
D>::CreateInstance(param::hstring const& id,
param::hstring const& primaryText,
param::hstring const& secondaryText,
winrt::Windows::Foundation::Uri const& lightModeIcon,
winrt::Windows::Foundation::Uri const& darkModeIcon)
const {
void* value{};
if constexpr (!std::is_same_v<D,
winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncementFactory>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result =
impl::try_as_with_reason<winrt::Microsoft::Windows::Widgets::
Notifications::IFeedAnnouncementFactory,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementFactory>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->CreateInstance(
*(void**)(&id), *(void**)(&primaryText), *(void**)(&secondaryText),
*(void**)(&lightModeIcon), *(void**)(&darkModeIcon), &value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementFactory>**)this;
check_hresult(_winrt_abi_type->CreateInstance(
*(void**)(&id), *(void**)(&primaryText), *(void**)(&secondaryText),
*(void**)(&lightModeIcon), *(void**)(&darkModeIcon), &value));
}
return winrt::Microsoft::Windows::Widgets::Notifications::FeedAnnouncement{
value, take_ownership_from_abi};
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncementInvokedArgs<
D>::FeedProviderDefinitionId() const {
void* value{};
if constexpr (!std::is_same_v<
D, winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_FeedProviderDefinitionId(&value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>**)this;
check_hresult(_winrt_abi_type->get_FeedProviderDefinitionId(&value));
}
return hstring{value, take_ownership_from_abi};
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncementInvokedArgs<
D>::FeedDefinitionId() const {
void* value{};
if constexpr (!std::is_same_v<
D, winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_FeedDefinitionId(&value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>**)this;
check_hresult(_winrt_abi_type->get_FeedDefinitionId(&value));
}
return hstring{value, take_ownership_from_abi};
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncementInvokedArgs<
D>::AnnouncementId() const {
void* value{};
if constexpr (!std::is_same_v<
D, winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>**)&_winrt_casted_result;
check_hresult(_winrt_abi_type->get_AnnouncementId(&value));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>**)this;
check_hresult(_winrt_abi_type->get_AnnouncementId(&value));
}
return hstring{value, take_ownership_from_abi};
}
template <typename D>
auto consume_Microsoft_Windows_Widgets_Notifications_IFeedAnnouncementInvokedArgs<
D>::ActionKind() const {
winrt::Microsoft::Windows::Widgets::Notifications::AnnouncementActionKind
value{};
if constexpr (!std::is_same_v<
D, winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>) {
winrt::hresult _winrt_cast_result_code;
auto const _winrt_casted_result = impl::try_as_with_reason<
winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs,
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::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>**)&_winrt_casted_result;
check_hresult(
_winrt_abi_type->get_ActionKind(reinterpret_cast<int32_t*>(&value)));
} else {
auto const _winrt_abi_type =
*(abi_t<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>**)this;
check_hresult(
_winrt_abi_type->get_ActionKind(reinterpret_cast<int32_t*>(&value)));
}
return value;
}
#ifndef WINRT_LEAN_AND_MEAN
template <typename D>
struct produce<
D, winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement>
: produce_base<D, winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncement> {
int32_t __stdcall get_Id(void** value) noexcept final try {
clear_abi(value);
typename D::abi_guard guard(this->shim());
*value = detach_from<hstring>(this->shim().Id());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall put_Id(void* value) noexcept final try {
typename D::abi_guard guard(this->shim());
this->shim().Id(*reinterpret_cast<hstring const*>(&value));
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_PrimaryText(void** value) noexcept final try {
clear_abi(value);
typename D::abi_guard guard(this->shim());
*value = detach_from<hstring>(this->shim().PrimaryText());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall put_PrimaryText(void* value) noexcept final try {
typename D::abi_guard guard(this->shim());
this->shim().PrimaryText(*reinterpret_cast<hstring const*>(&value));
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_SecondaryText(void** value) noexcept final try {
clear_abi(value);
typename D::abi_guard guard(this->shim());
*value = detach_from<hstring>(this->shim().SecondaryText());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall put_SecondaryText(void* value) noexcept final try {
typename D::abi_guard guard(this->shim());
this->shim().SecondaryText(*reinterpret_cast<hstring const*>(&value));
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_LightModeIconUri(void** value) noexcept final try {
clear_abi(value);
typename D::abi_guard guard(this->shim());
*value = detach_from<winrt::Windows::Foundation::Uri>(
this->shim().LightModeIconUri());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall put_LightModeIconUri(void* value) noexcept final try {
typename D::abi_guard guard(this->shim());
this->shim().LightModeIconUri(
*reinterpret_cast<winrt::Windows::Foundation::Uri const*>(&value));
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_DarkModeIconUri(void** value) noexcept final try {
clear_abi(value);
typename D::abi_guard guard(this->shim());
*value = detach_from<winrt::Windows::Foundation::Uri>(
this->shim().DarkModeIconUri());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall put_DarkModeIconUri(void* value) noexcept final try {
typename D::abi_guard guard(this->shim());
this->shim().DarkModeIconUri(
*reinterpret_cast<winrt::Windows::Foundation::Uri const*>(&value));
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_PrimaryTextColor(int32_t* value) noexcept final try {
typename D::abi_guard guard(this->shim());
*value =
detach_from<winrt::Microsoft::Windows::Widgets::Notifications::
AnnouncementTextColor>(this->shim().PrimaryTextColor());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall put_PrimaryTextColor(int32_t value) noexcept final try {
typename D::abi_guard guard(this->shim());
this->shim().PrimaryTextColor(
*reinterpret_cast<winrt::Microsoft::Windows::Widgets::Notifications::
AnnouncementTextColor const*>(&value));
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_SecondaryTextColor(int32_t* value) noexcept final try {
typename D::abi_guard guard(this->shim());
*value = detach_from<winrt::Microsoft::Windows::Widgets::Notifications::
AnnouncementTextColor>(
this->shim().SecondaryTextColor());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall put_SecondaryTextColor(int32_t value) noexcept final try {
typename D::abi_guard guard(this->shim());
this->shim().SecondaryTextColor(
*reinterpret_cast<winrt::Microsoft::Windows::Widgets::Notifications::
AnnouncementTextColor const*>(&value));
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_CustomAccessibilityText(void** value) noexcept final
try {
clear_abi(value);
typename D::abi_guard guard(this->shim());
*value = detach_from<hstring>(this->shim().CustomAccessibilityText());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall put_CustomAccessibilityText(void* value) noexcept final
try {
typename D::abi_guard guard(this->shim());
this->shim().CustomAccessibilityText(
*reinterpret_cast<hstring const*>(&value));
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_IsSecondaryTextSubtle(bool* value) noexcept final try {
typename D::abi_guard guard(this->shim());
*value = detach_from<bool>(this->shim().IsSecondaryTextSubtle());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall put_IsSecondaryTextSubtle(bool value) noexcept final try {
typename D::abi_guard guard(this->shim());
this->shim().IsSecondaryTextSubtle(value);
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_ShowBadgeIfUserNotEngaged(bool* value) noexcept final
try {
typename D::abi_guard guard(this->shim());
*value = detach_from<bool>(this->shim().ShowBadgeIfUserNotEngaged());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall put_ShowBadgeIfUserNotEngaged(bool value) noexcept final
try {
typename D::abi_guard guard(this->shim());
this->shim().ShowBadgeIfUserNotEngaged(value);
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_ExpirationTime(int64_t* value) noexcept final try {
zero_abi<winrt::Windows::Foundation::DateTime>(value);
typename D::abi_guard guard(this->shim());
*value = detach_from<winrt::Windows::Foundation::DateTime>(
this->shim().ExpirationTime());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall put_ExpirationTime(int64_t value) noexcept final try {
typename D::abi_guard guard(this->shim());
this->shim().ExpirationTime(
*reinterpret_cast<winrt::Windows::Foundation::DateTime const*>(&value));
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_Duration(int64_t* value) noexcept final try {
zero_abi<winrt::Windows::Foundation::TimeSpan>(value);
typename D::abi_guard guard(this->shim());
*value = detach_from<winrt::Windows::Foundation::TimeSpan>(
this->shim().Duration());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall put_Duration(int64_t value) noexcept final try {
typename D::abi_guard guard(this->shim());
this->shim().Duration(
*reinterpret_cast<winrt::Windows::Foundation::TimeSpan const*>(&value));
return 0;
} catch (...) {
return to_hresult();
}
};
#endif
#ifndef WINRT_LEAN_AND_MEAN
template <typename D>
struct produce<
D,
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncementFactory>
: produce_base<D, winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementFactory> {
int32_t __stdcall CreateInstance(void* id, void* primaryText,
void* secondaryText, void* lightModeIcon,
void* darkModeIcon,
void** value) noexcept final try {
clear_abi(value);
typename D::abi_guard guard(this->shim());
*value = detach_from<
winrt::Microsoft::Windows::Widgets::Notifications::FeedAnnouncement>(
this->shim().CreateInstance(
*reinterpret_cast<hstring const*>(&id),
*reinterpret_cast<hstring const*>(&primaryText),
*reinterpret_cast<hstring const*>(&secondaryText),
*reinterpret_cast<winrt::Windows::Foundation::Uri const*>(
&lightModeIcon),
*reinterpret_cast<winrt::Windows::Foundation::Uri const*>(
&darkModeIcon)));
return 0;
} catch (...) {
return to_hresult();
}
};
#endif
#ifndef WINRT_LEAN_AND_MEAN
template <typename D>
struct produce<D, winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs>
: produce_base<D, winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs> {
int32_t __stdcall get_FeedProviderDefinitionId(void** value) noexcept final
try {
clear_abi(value);
typename D::abi_guard guard(this->shim());
*value = detach_from<hstring>(this->shim().FeedProviderDefinitionId());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_FeedDefinitionId(void** value) noexcept final try {
clear_abi(value);
typename D::abi_guard guard(this->shim());
*value = detach_from<hstring>(this->shim().FeedDefinitionId());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_AnnouncementId(void** value) noexcept final try {
clear_abi(value);
typename D::abi_guard guard(this->shim());
*value = detach_from<hstring>(this->shim().AnnouncementId());
return 0;
} catch (...) {
return to_hresult();
}
int32_t __stdcall get_ActionKind(int32_t* value) noexcept final try {
typename D::abi_guard guard(this->shim());
*value = detach_from<winrt::Microsoft::Windows::Widgets::Notifications::
AnnouncementActionKind>(this->shim().ActionKind());
return 0;
} catch (...) {
return to_hresult();
}
};
#endif
} // namespace winrt::impl
WINRT_EXPORT namespace winrt::Microsoft::Windows::Widgets::Notifications {
inline FeedAnnouncement::FeedAnnouncement(
param::hstring const& id, param::hstring const& primaryText,
param::hstring const& secondaryText,
winrt::Windows::Foundation::Uri const& lightModeIcon,
winrt::Windows::Foundation::Uri const& darkModeIcon)
: FeedAnnouncement(
impl::call_factory<FeedAnnouncement, IFeedAnnouncementFactory>(
[&](IFeedAnnouncementFactory const& f) {
return f.CreateInstance(id, primaryText, secondaryText,
lightModeIcon, darkModeIcon);
})) {}
}
namespace std {
#ifndef WINRT_LEAN_AND_MEAN
template <>
struct hash<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncement>
: winrt::impl::hash_base {};
template <>
struct hash<
winrt::Microsoft::Windows::Widgets::Notifications::IFeedAnnouncementFactory>
: winrt::impl::hash_base {};
template <>
struct hash<winrt::Microsoft::Windows::Widgets::Notifications::
IFeedAnnouncementInvokedArgs> : winrt::impl::hash_base {};
template <>
struct hash<winrt::Microsoft::Windows::Widgets::Notifications::FeedAnnouncement>
: winrt::impl::hash_base {};
template <>
struct hash<winrt::Microsoft::Windows::Widgets::Notifications::
FeedAnnouncementInvokedArgs> : winrt::impl::hash_base {};
#endif
#ifdef __cpp_lib_format
#endif
} // namespace std
#endif