// C++/WinRT v2.0.250303.1 // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. #pragma once #ifndef WINRT_Windows_Web_Http_H #define WINRT_Windows_Web_Http_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/Windows.Web.h" #include "winrt/impl/Windows.Foundation.2.h" #include "winrt/impl/Windows.Foundation.Collections.2.h" #include "winrt/impl/Windows.Networking.Sockets.2.h" #include "winrt/impl/Windows.Security.Cryptography.Certificates.2.h" #include "winrt/impl/Windows.Storage.Streams.2.h" #include "winrt/impl/Windows.Web.Http.Filters.2.h" #include "winrt/impl/Windows.Web.Http.Headers.2.h" #include "winrt/impl/Windows.Web.Http.2.h" namespace winrt::impl { template auto consume_Windows_Web_Http_IHttpBufferContentFactory::CreateFromBuffer(winrt::Windows::Storage::Streams::IBuffer const& content) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->CreateFromBuffer(*(void**)(&content), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->CreateFromBuffer(*(void**)(&content), &value)); } return winrt::Windows::Web::Http::HttpBufferContent{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpBufferContentFactory::CreateFromBufferWithOffset(winrt::Windows::Storage::Streams::IBuffer const& content, uint32_t offset, uint32_t count) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->CreateFromBufferWithOffset(*(void**)(&content), offset, count, &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->CreateFromBufferWithOffset(*(void**)(&content), offset, count, &value)); } return winrt::Windows::Web::Http::HttpBufferContent{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient::DeleteAsync(winrt::Windows::Foundation::Uri const& uri) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->DeleteAsync(*(void**)(&uri), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->DeleteAsync(*(void**)(&uri), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient::GetAsync(winrt::Windows::Foundation::Uri const& uri) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->GetAsync(*(void**)(&uri), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->GetAsync(*(void**)(&uri), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient::GetAsync(winrt::Windows::Foundation::Uri const& uri, winrt::Windows::Web::Http::HttpCompletionOption const& completionOption) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->GetWithOptionAsync(*(void**)(&uri), static_cast(completionOption), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->GetWithOptionAsync(*(void**)(&uri), static_cast(completionOption), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient::GetBufferAsync(winrt::Windows::Foundation::Uri const& uri) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->GetBufferAsync(*(void**)(&uri), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->GetBufferAsync(*(void**)(&uri), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient::GetInputStreamAsync(winrt::Windows::Foundation::Uri const& uri) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->GetInputStreamAsync(*(void**)(&uri), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->GetInputStreamAsync(*(void**)(&uri), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient::GetStringAsync(winrt::Windows::Foundation::Uri const& uri) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->GetStringAsync(*(void**)(&uri), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->GetStringAsync(*(void**)(&uri), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient::PostAsync(winrt::Windows::Foundation::Uri const& uri, winrt::Windows::Web::Http::IHttpContent const& content) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->PostAsync(*(void**)(&uri), *(void**)(&content), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->PostAsync(*(void**)(&uri), *(void**)(&content), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient::PutAsync(winrt::Windows::Foundation::Uri const& uri, winrt::Windows::Web::Http::IHttpContent const& content) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->PutAsync(*(void**)(&uri), *(void**)(&content), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->PutAsync(*(void**)(&uri), *(void**)(&content), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient::SendRequestAsync(winrt::Windows::Web::Http::HttpRequestMessage const& request) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->SendRequestAsync(*(void**)(&request), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->SendRequestAsync(*(void**)(&request), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient::SendRequestAsync(winrt::Windows::Web::Http::HttpRequestMessage const& request, winrt::Windows::Web::Http::HttpCompletionOption const& completionOption) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->SendRequestWithOptionAsync(*(void**)(&request), static_cast(completionOption), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->SendRequestWithOptionAsync(*(void**)(&request), static_cast(completionOption), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient::DefaultRequestHeaders() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_DefaultRequestHeaders(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_DefaultRequestHeaders(&value)); } return winrt::Windows::Web::Http::Headers::HttpRequestHeaderCollection{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient2::TryDeleteAsync(winrt::Windows::Foundation::Uri const& uri) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->TryDeleteAsync(*(void**)(&uri), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->TryDeleteAsync(*(void**)(&uri), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient2::TryGetAsync(winrt::Windows::Foundation::Uri const& uri) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->TryGetAsync(*(void**)(&uri), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->TryGetAsync(*(void**)(&uri), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient2::TryGetAsync(winrt::Windows::Foundation::Uri const& uri, winrt::Windows::Web::Http::HttpCompletionOption const& completionOption) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->TryGetAsync2(*(void**)(&uri), static_cast(completionOption), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->TryGetAsync2(*(void**)(&uri), static_cast(completionOption), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient2::TryGetBufferAsync(winrt::Windows::Foundation::Uri const& uri) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->TryGetBufferAsync(*(void**)(&uri), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->TryGetBufferAsync(*(void**)(&uri), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient2::TryGetInputStreamAsync(winrt::Windows::Foundation::Uri const& uri) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->TryGetInputStreamAsync(*(void**)(&uri), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->TryGetInputStreamAsync(*(void**)(&uri), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient2::TryGetStringAsync(winrt::Windows::Foundation::Uri const& uri) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->TryGetStringAsync(*(void**)(&uri), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->TryGetStringAsync(*(void**)(&uri), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient2::TryPostAsync(winrt::Windows::Foundation::Uri const& uri, winrt::Windows::Web::Http::IHttpContent const& content) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->TryPostAsync(*(void**)(&uri), *(void**)(&content), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->TryPostAsync(*(void**)(&uri), *(void**)(&content), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient2::TryPutAsync(winrt::Windows::Foundation::Uri const& uri, winrt::Windows::Web::Http::IHttpContent const& content) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->TryPutAsync(*(void**)(&uri), *(void**)(&content), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->TryPutAsync(*(void**)(&uri), *(void**)(&content), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient2::TrySendRequestAsync(winrt::Windows::Web::Http::HttpRequestMessage const& request) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->TrySendRequestAsync(*(void**)(&request), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->TrySendRequestAsync(*(void**)(&request), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient2::TrySendRequestAsync(winrt::Windows::Web::Http::HttpRequestMessage const& request, winrt::Windows::Web::Http::HttpCompletionOption const& completionOption) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->TrySendRequestAsync2(*(void**)(&request), static_cast(completionOption), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->TrySendRequestAsync2(*(void**)(&request), static_cast(completionOption), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient3::DefaultPrivacyAnnotation() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_DefaultPrivacyAnnotation(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_DefaultPrivacyAnnotation(&value)); } return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpClient3::DefaultPrivacyAnnotation(param::hstring const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_DefaultPrivacyAnnotation(*(void**)(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_DefaultPrivacyAnnotation(*(void**)(&value))); } } template auto consume_Windows_Web_Http_IHttpClientFactory::Create(winrt::Windows::Web::Http::Filters::IHttpFilter const& filter) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->Create(*(void**)(&filter), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->Create(*(void**)(&filter), &value)); } return winrt::Windows::Web::Http::HttpClient{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpContent::Headers() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Headers(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Headers(&value)); } return winrt::Windows::Web::Http::Headers::HttpContentHeaderCollection{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpContent::BufferAllAsync() const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->BufferAllAsync(&operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->BufferAllAsync(&operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpContent::ReadAsBufferAsync() const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->ReadAsBufferAsync(&operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->ReadAsBufferAsync(&operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpContent::ReadAsInputStreamAsync() const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->ReadAsInputStreamAsync(&operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->ReadAsInputStreamAsync(&operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpContent::ReadAsStringAsync() const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->ReadAsStringAsync(&operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->ReadAsStringAsync(&operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpContent::TryComputeLength(uint64_t& length) const { bool succeeded{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->TryComputeLength(&length, &succeeded)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->TryComputeLength(&length, &succeeded)); } return succeeded; } template auto consume_Windows_Web_Http_IHttpContent::WriteToStreamAsync(winrt::Windows::Storage::Streams::IOutputStream const& outputStream) const { void* operation{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->WriteToStreamAsync(*(void**)(&outputStream), &operation)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->WriteToStreamAsync(*(void**)(&outputStream), &operation)); } return winrt::Windows::Foundation::IAsyncOperationWithProgress{ operation, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpCookie::Name() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Name(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Name(&value)); } return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpCookie::Domain() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Domain(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Domain(&value)); } return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpCookie::Path() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Path(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Path(&value)); } return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpCookie::Expires() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Expires(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Expires(&value)); } return winrt::Windows::Foundation::IReference{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpCookie::Expires(winrt::Windows::Foundation::IReference const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_Expires(*(void**)(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_Expires(*(void**)(&value))); } } template auto consume_Windows_Web_Http_IHttpCookie::HttpOnly() const { bool value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_HttpOnly(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_HttpOnly(&value)); } return value; } template auto consume_Windows_Web_Http_IHttpCookie::HttpOnly(bool value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_HttpOnly(value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_HttpOnly(value)); } } template auto consume_Windows_Web_Http_IHttpCookie::Secure() const { bool value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Secure(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Secure(&value)); } return value; } template auto consume_Windows_Web_Http_IHttpCookie::Secure(bool value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_Secure(value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_Secure(value)); } } template auto consume_Windows_Web_Http_IHttpCookie::Value() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Value(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Value(&value)); } return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpCookie::Value(param::hstring const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_Value(*(void**)(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_Value(*(void**)(&value))); } } template auto consume_Windows_Web_Http_IHttpCookieFactory::Create(param::hstring const& name, param::hstring const& domain, param::hstring const& path) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->Create(*(void**)(&name), *(void**)(&domain), *(void**)(&path), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->Create(*(void**)(&name), *(void**)(&domain), *(void**)(&path), &value)); } return winrt::Windows::Web::Http::HttpCookie{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpCookieManager::SetCookie(winrt::Windows::Web::Http::HttpCookie const& cookie) const { bool result{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->SetCookie(*(void**)(&cookie), &result)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->SetCookie(*(void**)(&cookie), &result)); } return result; } template auto consume_Windows_Web_Http_IHttpCookieManager::SetCookie(winrt::Windows::Web::Http::HttpCookie const& cookie, bool thirdParty) const { bool result{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->SetCookieWithThirdParty(*(void**)(&cookie), thirdParty, &result)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->SetCookieWithThirdParty(*(void**)(&cookie), thirdParty, &result)); } return result; } template auto consume_Windows_Web_Http_IHttpCookieManager::DeleteCookie(winrt::Windows::Web::Http::HttpCookie const& cookie) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->DeleteCookie(*(void**)(&cookie))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->DeleteCookie(*(void**)(&cookie))); } } template auto consume_Windows_Web_Http_IHttpCookieManager::GetCookies(winrt::Windows::Foundation::Uri const& uri) const { void* result{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->GetCookies(*(void**)(&uri), &result)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->GetCookies(*(void**)(&uri), &result)); } return winrt::Windows::Web::Http::HttpCookieCollection{ result, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpFormUrlEncodedContentFactory::Create(param::iterable> const& content) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->Create(*(void**)(&content), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->Create(*(void**)(&content), &value)); } return winrt::Windows::Web::Http::HttpFormUrlEncodedContent{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpGetBufferResult::ExtendedError() const { winrt::hresult value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value))); } return value; } template auto consume_Windows_Web_Http_IHttpGetBufferResult::RequestMessage() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_RequestMessage(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_RequestMessage(&value)); } return winrt::Windows::Web::Http::HttpRequestMessage{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpGetBufferResult::ResponseMessage() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ResponseMessage(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ResponseMessage(&value)); } return winrt::Windows::Web::Http::HttpResponseMessage{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpGetBufferResult::Succeeded() const { bool value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Succeeded(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Succeeded(&value)); } return value; } template auto consume_Windows_Web_Http_IHttpGetBufferResult::Value() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Value(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Value(&value)); } return winrt::Windows::Storage::Streams::IBuffer{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpGetInputStreamResult::ExtendedError() const { winrt::hresult value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value))); } return value; } template auto consume_Windows_Web_Http_IHttpGetInputStreamResult::RequestMessage() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_RequestMessage(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_RequestMessage(&value)); } return winrt::Windows::Web::Http::HttpRequestMessage{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpGetInputStreamResult::ResponseMessage() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ResponseMessage(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ResponseMessage(&value)); } return winrt::Windows::Web::Http::HttpResponseMessage{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpGetInputStreamResult::Succeeded() const { bool value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Succeeded(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Succeeded(&value)); } return value; } template auto consume_Windows_Web_Http_IHttpGetInputStreamResult::Value() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Value(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Value(&value)); } return winrt::Windows::Storage::Streams::IInputStream{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpGetStringResult::ExtendedError() const { winrt::hresult value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value))); } return value; } template auto consume_Windows_Web_Http_IHttpGetStringResult::RequestMessage() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_RequestMessage(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_RequestMessage(&value)); } return winrt::Windows::Web::Http::HttpRequestMessage{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpGetStringResult::ResponseMessage() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ResponseMessage(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ResponseMessage(&value)); } return winrt::Windows::Web::Http::HttpResponseMessage{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpGetStringResult::Succeeded() const { bool value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Succeeded(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Succeeded(&value)); } return value; } template auto consume_Windows_Web_Http_IHttpGetStringResult::Value() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Value(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Value(&value)); } return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpMethod::Method() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Method(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Method(&value)); } return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpMethodFactory::Create(param::hstring const& method) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->Create(*(void**)(&method), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->Create(*(void**)(&method), &value)); } return winrt::Windows::Web::Http::HttpMethod{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpMethodStatics::Delete() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Delete(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Delete(&value)); } return winrt::Windows::Web::Http::HttpMethod{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpMethodStatics::Get() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Get(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Get(&value)); } return winrt::Windows::Web::Http::HttpMethod{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpMethodStatics::Head() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Head(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Head(&value)); } return winrt::Windows::Web::Http::HttpMethod{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpMethodStatics::Options() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Options(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Options(&value)); } return winrt::Windows::Web::Http::HttpMethod{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpMethodStatics::Patch() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Patch(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Patch(&value)); } return winrt::Windows::Web::Http::HttpMethod{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpMethodStatics::Post() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Post(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Post(&value)); } return winrt::Windows::Web::Http::HttpMethod{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpMethodStatics::Put() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Put(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Put(&value)); } return winrt::Windows::Web::Http::HttpMethod{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpMultipartContent::Add(winrt::Windows::Web::Http::IHttpContent const& content) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->Add(*(void**)(&content))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->Add(*(void**)(&content))); } } template auto consume_Windows_Web_Http_IHttpMultipartContentFactory::CreateWithSubtype(param::hstring const& subtype) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->CreateWithSubtype(*(void**)(&subtype), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->CreateWithSubtype(*(void**)(&subtype), &value)); } return winrt::Windows::Web::Http::HttpMultipartContent{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpMultipartContentFactory::CreateWithSubtypeAndBoundary(param::hstring const& subtype, param::hstring const& boundary) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->CreateWithSubtypeAndBoundary(*(void**)(&subtype), *(void**)(&boundary), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->CreateWithSubtypeAndBoundary(*(void**)(&subtype), *(void**)(&boundary), &value)); } return winrt::Windows::Web::Http::HttpMultipartContent{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpMultipartFormDataContent::Add(winrt::Windows::Web::Http::IHttpContent const& content) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->Add(*(void**)(&content))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->Add(*(void**)(&content))); } } template auto consume_Windows_Web_Http_IHttpMultipartFormDataContent::Add(winrt::Windows::Web::Http::IHttpContent const& content, param::hstring const& name) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->AddWithName(*(void**)(&content), *(void**)(&name))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->AddWithName(*(void**)(&content), *(void**)(&name))); } } template auto consume_Windows_Web_Http_IHttpMultipartFormDataContent::Add(winrt::Windows::Web::Http::IHttpContent const& content, param::hstring const& name, param::hstring const& fileName) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->AddWithNameAndFileName(*(void**)(&content), *(void**)(&name), *(void**)(&fileName))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->AddWithNameAndFileName(*(void**)(&content), *(void**)(&name), *(void**)(&fileName))); } } template auto consume_Windows_Web_Http_IHttpMultipartFormDataContentFactory::CreateWithBoundary(param::hstring const& boundary) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->CreateWithBoundary(*(void**)(&boundary), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->CreateWithBoundary(*(void**)(&boundary), &value)); } return winrt::Windows::Web::Http::HttpMultipartFormDataContent{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpRequestMessage::Content() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Content(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Content(&value)); } return winrt::Windows::Web::Http::IHttpContent{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpRequestMessage::Content(winrt::Windows::Web::Http::IHttpContent const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_Content(*(void**)(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_Content(*(void**)(&value))); } } template auto consume_Windows_Web_Http_IHttpRequestMessage::Headers() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Headers(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Headers(&value)); } return winrt::Windows::Web::Http::Headers::HttpRequestHeaderCollection{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpRequestMessage::Method() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Method(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Method(&value)); } return winrt::Windows::Web::Http::HttpMethod{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpRequestMessage::Method(winrt::Windows::Web::Http::HttpMethod const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_Method(*(void**)(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_Method(*(void**)(&value))); } } template auto consume_Windows_Web_Http_IHttpRequestMessage::Properties() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Properties(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Properties(&value)); } return winrt::Windows::Foundation::Collections::IMap{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpRequestMessage::RequestUri() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_RequestUri(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_RequestUri(&value)); } return winrt::Windows::Foundation::Uri{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpRequestMessage::RequestUri(winrt::Windows::Foundation::Uri const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_RequestUri(*(void**)(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_RequestUri(*(void**)(&value))); } } template auto consume_Windows_Web_Http_IHttpRequestMessage::TransportInformation() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_TransportInformation(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_TransportInformation(&value)); } return winrt::Windows::Web::Http::HttpTransportInformation{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpRequestMessage2::PrivacyAnnotation() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_PrivacyAnnotation(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_PrivacyAnnotation(&value)); } return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpRequestMessage2::PrivacyAnnotation(param::hstring const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_PrivacyAnnotation(*(void**)(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_PrivacyAnnotation(*(void**)(&value))); } } template auto consume_Windows_Web_Http_IHttpRequestMessageFactory::Create(winrt::Windows::Web::Http::HttpMethod const& method, winrt::Windows::Foundation::Uri const& uri) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->Create(*(void**)(&method), *(void**)(&uri), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->Create(*(void**)(&method), *(void**)(&uri), &value)); } return winrt::Windows::Web::Http::HttpRequestMessage{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpRequestResult::ExtendedError() const { winrt::hresult value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ExtendedError(put_abi(value))); } return value; } template auto consume_Windows_Web_Http_IHttpRequestResult::RequestMessage() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_RequestMessage(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_RequestMessage(&value)); } return winrt::Windows::Web::Http::HttpRequestMessage{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpRequestResult::ResponseMessage() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ResponseMessage(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ResponseMessage(&value)); } return winrt::Windows::Web::Http::HttpResponseMessage{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpRequestResult::Succeeded() const { bool value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Succeeded(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Succeeded(&value)); } return value; } template auto consume_Windows_Web_Http_IHttpResponseMessage::Content() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Content(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Content(&value)); } return winrt::Windows::Web::Http::IHttpContent{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpResponseMessage::Content(winrt::Windows::Web::Http::IHttpContent const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_Content(*(void**)(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_Content(*(void**)(&value))); } } template auto consume_Windows_Web_Http_IHttpResponseMessage::Headers() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Headers(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Headers(&value)); } return winrt::Windows::Web::Http::Headers::HttpResponseHeaderCollection{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpResponseMessage::IsSuccessStatusCode() const { bool value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_IsSuccessStatusCode(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_IsSuccessStatusCode(&value)); } return value; } template auto consume_Windows_Web_Http_IHttpResponseMessage::ReasonPhrase() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ReasonPhrase(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ReasonPhrase(&value)); } return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpResponseMessage::ReasonPhrase(param::hstring const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_ReasonPhrase(*(void**)(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_ReasonPhrase(*(void**)(&value))); } } template auto consume_Windows_Web_Http_IHttpResponseMessage::RequestMessage() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_RequestMessage(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_RequestMessage(&value)); } return winrt::Windows::Web::Http::HttpRequestMessage{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpResponseMessage::RequestMessage(winrt::Windows::Web::Http::HttpRequestMessage const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_RequestMessage(*(void**)(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_RequestMessage(*(void**)(&value))); } } template auto consume_Windows_Web_Http_IHttpResponseMessage::Source() const { winrt::Windows::Web::Http::HttpResponseMessageSource value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Source(reinterpret_cast(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Source(reinterpret_cast(&value))); } return value; } template auto consume_Windows_Web_Http_IHttpResponseMessage::Source(winrt::Windows::Web::Http::HttpResponseMessageSource const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_Source(static_cast(value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_Source(static_cast(value))); } } template auto consume_Windows_Web_Http_IHttpResponseMessage::StatusCode() const { winrt::Windows::Web::Http::HttpStatusCode value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_StatusCode(reinterpret_cast(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_StatusCode(reinterpret_cast(&value))); } return value; } template auto consume_Windows_Web_Http_IHttpResponseMessage::StatusCode(winrt::Windows::Web::Http::HttpStatusCode const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_StatusCode(static_cast(value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_StatusCode(static_cast(value))); } } template auto consume_Windows_Web_Http_IHttpResponseMessage::Version() const { winrt::Windows::Web::Http::HttpVersion value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_Version(reinterpret_cast(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_Version(reinterpret_cast(&value))); } return value; } template auto consume_Windows_Web_Http_IHttpResponseMessage::Version(winrt::Windows::Web::Http::HttpVersion const& value) const { if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->put_Version(static_cast(value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->put_Version(static_cast(value))); } } template auto consume_Windows_Web_Http_IHttpResponseMessage::EnsureSuccessStatusCode() const { void* result{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->EnsureSuccessStatusCode(&result)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->EnsureSuccessStatusCode(&result)); } return winrt::Windows::Web::Http::HttpResponseMessage{ result, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpResponseMessageFactory::Create(winrt::Windows::Web::Http::HttpStatusCode const& statusCode) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->Create(static_cast(statusCode), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->Create(static_cast(statusCode), &value)); } return winrt::Windows::Web::Http::HttpResponseMessage{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpStreamContentFactory::CreateFromInputStream(winrt::Windows::Storage::Streams::IInputStream const& content) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->CreateFromInputStream(*(void**)(&content), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->CreateFromInputStream(*(void**)(&content), &value)); } return winrt::Windows::Web::Http::HttpStreamContent{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpStringContentFactory::CreateFromString(param::hstring const& content) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->CreateFromString(*(void**)(&content), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->CreateFromString(*(void**)(&content), &value)); } return winrt::Windows::Web::Http::HttpStringContent{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpStringContentFactory::CreateFromStringWithEncoding(param::hstring const& content, winrt::Windows::Storage::Streams::UnicodeEncoding const& encoding) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->CreateFromStringWithEncoding(*(void**)(&content), static_cast(encoding), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->CreateFromStringWithEncoding(*(void**)(&content), static_cast(encoding), &value)); } return winrt::Windows::Web::Http::HttpStringContent{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpStringContentFactory::CreateFromStringWithEncodingAndMediaType(param::hstring const& content, winrt::Windows::Storage::Streams::UnicodeEncoding const& encoding, param::hstring const& mediaType) const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->CreateFromStringWithEncodingAndMediaType(*(void**)(&content), static_cast(encoding), *(void**)(&mediaType), &value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->CreateFromStringWithEncodingAndMediaType(*(void**)(&content), static_cast(encoding), *(void**)(&mediaType), &value)); } return winrt::Windows::Web::Http::HttpStringContent{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpTransportInformation::ServerCertificate() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ServerCertificate(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ServerCertificate(&value)); } return winrt::Windows::Security::Cryptography::Certificates::Certificate{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpTransportInformation::ServerCertificateErrorSeverity() const { winrt::Windows::Networking::Sockets::SocketSslErrorSeverity value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ServerCertificateErrorSeverity(reinterpret_cast(&value))); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ServerCertificateErrorSeverity(reinterpret_cast(&value))); } return value; } template auto consume_Windows_Web_Http_IHttpTransportInformation::ServerCertificateErrors() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ServerCertificateErrors(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ServerCertificateErrors(&value)); } return winrt::Windows::Foundation::Collections::IVectorView{ value, take_ownership_from_abi }; } template auto consume_Windows_Web_Http_IHttpTransportInformation::ServerIntermediateCertificates() const { void* value{}; if constexpr (!std::is_same_v) { winrt::hresult _winrt_cast_result_code; auto const _winrt_casted_result = impl::try_as_with_reason(static_cast(this), _winrt_cast_result_code); check_hresult(_winrt_cast_result_code); auto const _winrt_abi_type = *(abi_t**)&_winrt_casted_result; check_hresult(_winrt_abi_type->get_ServerIntermediateCertificates(&value)); } else { auto const _winrt_abi_type = *(abi_t**)this; check_hresult(_winrt_abi_type->get_ServerIntermediateCertificates(&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 CreateFromBuffer(void* content, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().CreateFromBuffer(*reinterpret_cast(&content))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall CreateFromBufferWithOffset(void* content, uint32_t offset, uint32_t count, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().CreateFromBufferWithOffset(*reinterpret_cast(&content), offset, count)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall DeleteAsync(void* uri, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().DeleteAsync(*reinterpret_cast(&uri))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall GetAsync(void* uri, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().GetAsync(*reinterpret_cast(&uri))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall GetWithOptionAsync(void* uri, int32_t completionOption, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().GetAsync(*reinterpret_cast(&uri), *reinterpret_cast(&completionOption))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall GetBufferAsync(void* uri, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().GetBufferAsync(*reinterpret_cast(&uri))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall GetInputStreamAsync(void* uri, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().GetInputStreamAsync(*reinterpret_cast(&uri))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall GetStringAsync(void* uri, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().GetStringAsync(*reinterpret_cast(&uri))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall PostAsync(void* uri, void* content, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().PostAsync(*reinterpret_cast(&uri), *reinterpret_cast(&content))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall PutAsync(void* uri, void* content, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().PutAsync(*reinterpret_cast(&uri), *reinterpret_cast(&content))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall SendRequestAsync(void* request, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().SendRequestAsync(*reinterpret_cast(&request))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall SendRequestWithOptionAsync(void* request, int32_t completionOption, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().SendRequestAsync(*reinterpret_cast(&request), *reinterpret_cast(&completionOption))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_DefaultRequestHeaders(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().DefaultRequestHeaders()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall TryDeleteAsync(void* uri, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().TryDeleteAsync(*reinterpret_cast(&uri))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall TryGetAsync(void* uri, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().TryGetAsync(*reinterpret_cast(&uri))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall TryGetAsync2(void* uri, int32_t completionOption, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().TryGetAsync(*reinterpret_cast(&uri), *reinterpret_cast(&completionOption))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall TryGetBufferAsync(void* uri, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().TryGetBufferAsync(*reinterpret_cast(&uri))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall TryGetInputStreamAsync(void* uri, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().TryGetInputStreamAsync(*reinterpret_cast(&uri))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall TryGetStringAsync(void* uri, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().TryGetStringAsync(*reinterpret_cast(&uri))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall TryPostAsync(void* uri, void* content, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().TryPostAsync(*reinterpret_cast(&uri), *reinterpret_cast(&content))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall TryPutAsync(void* uri, void* content, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().TryPutAsync(*reinterpret_cast(&uri), *reinterpret_cast(&content))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall TrySendRequestAsync(void* request, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().TrySendRequestAsync(*reinterpret_cast(&request))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall TrySendRequestAsync2(void* request, int32_t completionOption, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().TrySendRequestAsync(*reinterpret_cast(&request), *reinterpret_cast(&completionOption))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_DefaultPrivacyAnnotation(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().DefaultPrivacyAnnotation()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_DefaultPrivacyAnnotation(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().DefaultPrivacyAnnotation(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall Create(void* filter, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Create(*reinterpret_cast(&filter))); return 0; } catch (...) { return to_hresult(); } }; #endif template struct produce : produce_base { int32_t __stdcall get_Headers(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Headers()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall BufferAllAsync(void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().BufferAllAsync()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ReadAsBufferAsync(void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().ReadAsBufferAsync()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ReadAsInputStreamAsync(void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().ReadAsInputStreamAsync()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ReadAsStringAsync(void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().ReadAsStringAsync()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall TryComputeLength(uint64_t* length, bool* succeeded) noexcept final try { typename D::abi_guard guard(this->shim()); *succeeded = detach_from(this->shim().TryComputeLength(*length)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall WriteToStreamAsync(void* outputStream, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().WriteToStreamAsync(*reinterpret_cast(&outputStream))); return 0; } catch (...) { return to_hresult(); } }; #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Name(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Name()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Domain(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Domain()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Path(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Path()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Expires(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().Expires()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Expires(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Expires(*reinterpret_cast const*>(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_HttpOnly(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().HttpOnly()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_HttpOnly(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().HttpOnly(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Secure(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Secure()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Secure(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Secure(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Value(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Value()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Value(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Value(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall Create(void* name, void* domain, void* path, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Create(*reinterpret_cast(&name), *reinterpret_cast(&domain), *reinterpret_cast(&path))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall SetCookie(void* cookie, bool* result) noexcept final try { typename D::abi_guard guard(this->shim()); *result = detach_from(this->shim().SetCookie(*reinterpret_cast(&cookie))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall SetCookieWithThirdParty(void* cookie, bool thirdParty, bool* result) noexcept final try { typename D::abi_guard guard(this->shim()); *result = detach_from(this->shim().SetCookie(*reinterpret_cast(&cookie), thirdParty)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall DeleteCookie(void* cookie) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().DeleteCookie(*reinterpret_cast(&cookie)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall GetCookies(void* uri, void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from(this->shim().GetCookies(*reinterpret_cast(&uri))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall Create(void* content, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Create(*reinterpret_cast> const*>(&content))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_ExtendedError(winrt::hresult* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ExtendedError()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_RequestMessage(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().RequestMessage()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ResponseMessage(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ResponseMessage()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Succeeded(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Succeeded()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Value(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Value()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_ExtendedError(winrt::hresult* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ExtendedError()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_RequestMessage(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().RequestMessage()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ResponseMessage(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ResponseMessage()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Succeeded(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Succeeded()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Value(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Value()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_ExtendedError(winrt::hresult* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ExtendedError()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_RequestMessage(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().RequestMessage()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ResponseMessage(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ResponseMessage()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Succeeded(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Succeeded()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Value(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Value()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Method(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Method()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall Create(void* method, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Create(*reinterpret_cast(&method))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Delete(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Delete()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Get(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Get()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Head(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Head()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Options(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Options()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Patch(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Patch()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Post(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Post()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Put(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Put()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall Add(void* content) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Add(*reinterpret_cast(&content)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall CreateWithSubtype(void* subtype, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().CreateWithSubtype(*reinterpret_cast(&subtype))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall CreateWithSubtypeAndBoundary(void* subtype, void* boundary, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().CreateWithSubtypeAndBoundary(*reinterpret_cast(&subtype), *reinterpret_cast(&boundary))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall Add(void* content) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Add(*reinterpret_cast(&content)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall AddWithName(void* content, void* name) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Add(*reinterpret_cast(&content), *reinterpret_cast(&name)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall AddWithNameAndFileName(void* content, void* name, void* fileName) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Add(*reinterpret_cast(&content), *reinterpret_cast(&name), *reinterpret_cast(&fileName)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall CreateWithBoundary(void* boundary, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().CreateWithBoundary(*reinterpret_cast(&boundary))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Content(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Content()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Content(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Content(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Headers(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Headers()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Method(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Method()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Method(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Method(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Properties(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().Properties()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_RequestUri(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().RequestUri()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_RequestUri(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RequestUri(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_TransportInformation(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().TransportInformation()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_PrivacyAnnotation(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().PrivacyAnnotation()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_PrivacyAnnotation(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().PrivacyAnnotation(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall Create(void* method, void* uri, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Create(*reinterpret_cast(&method), *reinterpret_cast(&uri))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_ExtendedError(winrt::hresult* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ExtendedError()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_RequestMessage(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().RequestMessage()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ResponseMessage(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ResponseMessage()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Succeeded(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Succeeded()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Content(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Content()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Content(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Content(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Headers(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Headers()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsSuccessStatusCode(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsSuccessStatusCode()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ReasonPhrase(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ReasonPhrase()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_ReasonPhrase(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ReasonPhrase(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_RequestMessage(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().RequestMessage()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_RequestMessage(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RequestMessage(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Source(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Source()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Source(int32_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Source(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_StatusCode(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().StatusCode()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_StatusCode(int32_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().StatusCode(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Version(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Version()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Version(int32_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Version(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall EnsureSuccessStatusCode(void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from(this->shim().EnsureSuccessStatusCode()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall Create(int32_t statusCode, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Create(*reinterpret_cast(&statusCode))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall CreateFromInputStream(void* content, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().CreateFromInputStream(*reinterpret_cast(&content))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall CreateFromString(void* content, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().CreateFromString(*reinterpret_cast(&content))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall CreateFromStringWithEncoding(void* content, int32_t encoding, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().CreateFromStringWithEncoding(*reinterpret_cast(&content), *reinterpret_cast(&encoding))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall CreateFromStringWithEncodingAndMediaType(void* content, int32_t encoding, void* mediaType, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().CreateFromStringWithEncodingAndMediaType(*reinterpret_cast(&content), *reinterpret_cast(&encoding), *reinterpret_cast(&mediaType))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_ServerCertificate(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ServerCertificate()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ServerCertificateErrorSeverity(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ServerCertificateErrorSeverity()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ServerCertificateErrors(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().ServerCertificateErrors()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ServerIntermediateCertificates(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().ServerIntermediateCertificates()); return 0; } catch (...) { return to_hresult(); } }; #endif } WINRT_EXPORT namespace winrt::Windows::Web::Http { inline HttpBufferContent::HttpBufferContent(winrt::Windows::Storage::Streams::IBuffer const& content) : HttpBufferContent(impl::call_factory([&](IHttpBufferContentFactory const& f) { return f.CreateFromBuffer(content); })) { } inline HttpBufferContent::HttpBufferContent(winrt::Windows::Storage::Streams::IBuffer const& content, uint32_t offset, uint32_t count) : HttpBufferContent(impl::call_factory([&](IHttpBufferContentFactory const& f) { return f.CreateFromBufferWithOffset(content, offset, count); })) { } inline HttpClient::HttpClient() : HttpClient(impl::call_factory_cast([](winrt::Windows::Foundation::IActivationFactory const& f) { return f.template ActivateInstance(); })) { } inline HttpClient::HttpClient(winrt::Windows::Web::Http::Filters::IHttpFilter const& filter) : HttpClient(impl::call_factory([&](IHttpClientFactory const& f) { return f.Create(filter); })) { } inline HttpCookie::HttpCookie(param::hstring const& name, param::hstring const& domain, param::hstring const& path) : HttpCookie(impl::call_factory([&](IHttpCookieFactory const& f) { return f.Create(name, domain, path); })) { } inline HttpFormUrlEncodedContent::HttpFormUrlEncodedContent(param::iterable> const& content) : HttpFormUrlEncodedContent(impl::call_factory([&](IHttpFormUrlEncodedContentFactory const& f) { return f.Create(content); })) { } inline HttpMethod::HttpMethod(param::hstring const& method) : HttpMethod(impl::call_factory([&](IHttpMethodFactory const& f) { return f.Create(method); })) { } inline auto HttpMethod::Delete() { return impl::call_factory_cast([](IHttpMethodStatics const& f) { return f.Delete(); }); } inline auto HttpMethod::Get() { return impl::call_factory_cast([](IHttpMethodStatics const& f) { return f.Get(); }); } inline auto HttpMethod::Head() { return impl::call_factory_cast([](IHttpMethodStatics const& f) { return f.Head(); }); } inline auto HttpMethod::Options() { return impl::call_factory_cast([](IHttpMethodStatics const& f) { return f.Options(); }); } inline auto HttpMethod::Patch() { return impl::call_factory_cast([](IHttpMethodStatics const& f) { return f.Patch(); }); } inline auto HttpMethod::Post() { return impl::call_factory_cast([](IHttpMethodStatics const& f) { return f.Post(); }); } inline auto HttpMethod::Put() { return impl::call_factory_cast([](IHttpMethodStatics const& f) { return f.Put(); }); } inline HttpMultipartContent::HttpMultipartContent() : HttpMultipartContent(impl::call_factory_cast([](winrt::Windows::Foundation::IActivationFactory const& f) { return f.template ActivateInstance(); })) { } inline HttpMultipartContent::HttpMultipartContent(param::hstring const& subtype) : HttpMultipartContent(impl::call_factory([&](IHttpMultipartContentFactory const& f) { return f.CreateWithSubtype(subtype); })) { } inline HttpMultipartContent::HttpMultipartContent(param::hstring const& subtype, param::hstring const& boundary) : HttpMultipartContent(impl::call_factory([&](IHttpMultipartContentFactory const& f) { return f.CreateWithSubtypeAndBoundary(subtype, boundary); })) { } inline HttpMultipartFormDataContent::HttpMultipartFormDataContent() : HttpMultipartFormDataContent(impl::call_factory_cast([](winrt::Windows::Foundation::IActivationFactory const& f) { return f.template ActivateInstance(); })) { } inline HttpMultipartFormDataContent::HttpMultipartFormDataContent(param::hstring const& boundary) : HttpMultipartFormDataContent(impl::call_factory([&](IHttpMultipartFormDataContentFactory const& f) { return f.CreateWithBoundary(boundary); })) { } inline HttpRequestMessage::HttpRequestMessage() : HttpRequestMessage(impl::call_factory_cast([](winrt::Windows::Foundation::IActivationFactory const& f) { return f.template ActivateInstance(); })) { } inline HttpRequestMessage::HttpRequestMessage(winrt::Windows::Web::Http::HttpMethod const& method, winrt::Windows::Foundation::Uri const& uri) : HttpRequestMessage(impl::call_factory([&](IHttpRequestMessageFactory const& f) { return f.Create(method, uri); })) { } inline HttpResponseMessage::HttpResponseMessage() : HttpResponseMessage(impl::call_factory_cast([](winrt::Windows::Foundation::IActivationFactory const& f) { return f.template ActivateInstance(); })) { } inline HttpResponseMessage::HttpResponseMessage(winrt::Windows::Web::Http::HttpStatusCode const& statusCode) : HttpResponseMessage(impl::call_factory([&](IHttpResponseMessageFactory const& f) { return f.Create(statusCode); })) { } inline HttpStreamContent::HttpStreamContent(winrt::Windows::Storage::Streams::IInputStream const& content) : HttpStreamContent(impl::call_factory([&](IHttpStreamContentFactory const& f) { return f.CreateFromInputStream(content); })) { } inline HttpStringContent::HttpStringContent(param::hstring const& content) : HttpStringContent(impl::call_factory([&](IHttpStringContentFactory const& f) { return f.CreateFromString(content); })) { } inline HttpStringContent::HttpStringContent(param::hstring const& content, winrt::Windows::Storage::Streams::UnicodeEncoding const& encoding) : HttpStringContent(impl::call_factory([&](IHttpStringContentFactory const& f) { return f.CreateFromStringWithEncoding(content, encoding); })) { } inline HttpStringContent::HttpStringContent(param::hstring const& content, winrt::Windows::Storage::Streams::UnicodeEncoding const& encoding, param::hstring const& mediaType) : HttpStringContent(impl::call_factory([&](IHttpStringContentFactory const& f) { return f.CreateFromStringWithEncodingAndMediaType(content, encoding, mediaType); })) { } } 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 {}; 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 {}; 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 {}; 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 {}; 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 {}; 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 {}; 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 {}; 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 template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; template<> struct formatter : formatter {}; #endif } #endif