// WARNING: Please don't edit this file. It was generated by C++/WinRT v2.0.240405.15 #pragma once #ifndef WINRT_Windows_ApplicationModel_DataTransfer_ShareTarget_H #define WINRT_Windows_ApplicationModel_DataTransfer_ShareTarget_H #include "winrt/base.h" static_assert(winrt::check_version(CPPWINRT_VERSION, "2.0.240405.15"), "Mismatched C++/WinRT headers."); #define CPPWINRT_VERSION "2.0.240405.15" #include "winrt/Windows.ApplicationModel.DataTransfer.h" #include "winrt/impl/Windows.ApplicationModel.Contacts.2.h" #include "winrt/impl/Windows.ApplicationModel.DataTransfer.2.h" #include "winrt/impl/Windows.Foundation.Collections.2.h" #include "winrt/impl/Windows.Storage.Streams.2.h" #include "winrt/impl/Windows.ApplicationModel.DataTransfer.ShareTarget.2.h" namespace winrt::impl { template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IQuickLink::Title() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IQuickLink)->get_Title(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IQuickLink::Title(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IQuickLink)->put_Title(*(void**)(&value))); } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IQuickLink::Thumbnail() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IQuickLink)->get_Thumbnail(&value)); return winrt::Windows::Storage::Streams::RandomAccessStreamReference{ value, take_ownership_from_abi }; } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IQuickLink::Thumbnail(winrt::Windows::Storage::Streams::RandomAccessStreamReference const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IQuickLink)->put_Thumbnail(*(void**)(&value))); } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IQuickLink::Id() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IQuickLink)->get_Id(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IQuickLink::Id(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IQuickLink)->put_Id(*(void**)(&value))); } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IQuickLink::SupportedDataFormats() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IQuickLink)->get_SupportedDataFormats(&value)); return winrt::Windows::Foundation::Collections::IVector{ value, take_ownership_from_abi }; } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IQuickLink::SupportedFileTypes() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IQuickLink)->get_SupportedFileTypes(&value)); return winrt::Windows::Foundation::Collections::IVector{ value, take_ownership_from_abi }; } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IShareOperation::Data() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IShareOperation)->get_Data(&value)); return winrt::Windows::ApplicationModel::DataTransfer::DataPackageView{ value, take_ownership_from_abi }; } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IShareOperation::QuickLinkId() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IShareOperation)->get_QuickLinkId(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IShareOperation::RemoveThisQuickLink() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IShareOperation)->RemoveThisQuickLink()); } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IShareOperation::ReportStarted() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IShareOperation)->ReportStarted()); } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IShareOperation::ReportDataRetrieved() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IShareOperation)->ReportDataRetrieved()); } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IShareOperation::ReportSubmittedBackgroundTask() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IShareOperation)->ReportSubmittedBackgroundTask()); } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IShareOperation::ReportCompleted(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::QuickLink const& quicklink) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IShareOperation)->ReportCompletedWithQuickLink(*(void**)(&quicklink))); } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IShareOperation::ReportCompleted() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IShareOperation)->ReportCompleted()); } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IShareOperation::ReportError(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IShareOperation)->ReportError(*(void**)(&value))); } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IShareOperation2::DismissUI() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IShareOperation2)->DismissUI()); } template auto consume_Windows_ApplicationModel_DataTransfer_ShareTarget_IShareOperation3::Contacts() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::ApplicationModel::DataTransfer::ShareTarget::IShareOperation3)->get_Contacts(&value)); return winrt::Windows::Foundation::Collections::IVectorView{ value, take_ownership_from_abi }; } #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Title(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Title()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Title(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Title(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Thumbnail(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Thumbnail()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Thumbnail(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Thumbnail(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Id(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(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(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_SupportedDataFormats(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().SupportedDataFormats()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_SupportedFileTypes(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().SupportedFileTypes()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Data(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Data()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_QuickLinkId(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().QuickLinkId()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall RemoveThisQuickLink() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RemoveThisQuickLink(); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ReportStarted() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ReportStarted(); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ReportDataRetrieved() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ReportDataRetrieved(); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ReportSubmittedBackgroundTask() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ReportSubmittedBackgroundTask(); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ReportCompletedWithQuickLink(void* quicklink) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ReportCompleted(*reinterpret_cast(&quicklink)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ReportCompleted() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ReportCompleted(); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ReportError(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ReportError(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall DismissUI() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().DismissUI(); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Contacts(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().Contacts()); return 0; } catch (...) { return to_hresult(); } }; #endif } WINRT_EXPORT namespace winrt::Windows::ApplicationModel::DataTransfer::ShareTarget { inline QuickLink::QuickLink() : QuickLink(impl::call_factory_cast([](winrt::Windows::Foundation::IActivationFactory const& f) { return f.template ActivateInstance(); })) { } } namespace std { #ifndef WINRT_LEAN_AND_MEAN template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; #endif #ifdef __cpp_lib_format #endif } #endif