// WARNING: Please don't edit this file. It was generated by C++/WinRT v2.0.240405.15 #pragma once #ifndef WINRT_Windows_Devices_WiFiDirect_Services_H #define WINRT_Windows_Devices_WiFiDirect_Services_H #include "winrt/base.h" static_assert(winrt::check_version(CPPWINRT_VERSION, "2.0.240405.15"), "Mismatched C++/WinRT headers."); #define CPPWINRT_VERSION "2.0.240405.15" #include "winrt/Windows.Devices.WiFiDirect.h" #include "winrt/impl/Windows.Devices.Enumeration.2.h" #include "winrt/impl/Windows.Foundation.2.h" #include "winrt/impl/Windows.Foundation.Collections.2.h" #include "winrt/impl/Windows.Networking.2.h" #include "winrt/impl/Windows.Networking.Sockets.2.h" #include "winrt/impl/Windows.Storage.Streams.2.h" #include "winrt/impl/Windows.Devices.WiFiDirect.Services.2.h" namespace winrt::impl { template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::RemoteServiceInfo() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectService)->get_RemoteServiceInfo(&value)); return winrt::Windows::Storage::Streams::IBuffer{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::SupportedConfigurationMethods() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectService)->get_SupportedConfigurationMethods(&value)); return winrt::Windows::Foundation::Collections::IVectorView{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::PreferGroupOwnerMode() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectService)->get_PreferGroupOwnerMode(&value)); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::PreferGroupOwnerMode(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectService)->put_PreferGroupOwnerMode(value)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::SessionInfo() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectService)->get_SessionInfo(&value)); return winrt::Windows::Storage::Streams::IBuffer{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::SessionInfo(winrt::Windows::Storage::Streams::IBuffer const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectService)->put_SessionInfo(*(void**)(&value))); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::ServiceError() const { winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceError value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectService)->get_ServiceError(reinterpret_cast(&value))); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::SessionDeferred(winrt::Windows::Foundation::TypedEventHandler const& handler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectService)->add_SessionDeferred(*(void**)(&handler), put_abi(token))); return token; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::SessionDeferred(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& handler) const { return impl::make_event_revoker(this, SessionDeferred(handler)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::SessionDeferred(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectService)->remove_SessionDeferred(impl::bind_in(token)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::GetProvisioningInfoAsync(winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceConfigurationMethod const& selectedConfigurationMethod) const { void* result{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectService)->GetProvisioningInfoAsync(static_cast(selectedConfigurationMethod), &result)); return winrt::Windows::Foundation::IAsyncOperation{ result, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::ConnectAsync() const { void* result{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectService)->ConnectAsync(&result)); return winrt::Windows::Foundation::IAsyncOperation{ result, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectService::ConnectAsync(param::hstring const& pin) const { void* result{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectService)->ConnectAsyncWithPin(*(void**)(&pin), &result)); return winrt::Windows::Foundation::IAsyncOperation{ result, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::ServiceName() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->get_ServiceName(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::ServiceNamePrefixes() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->get_ServiceNamePrefixes(&value)); return winrt::Windows::Foundation::Collections::IVector{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::ServiceInfo() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->get_ServiceInfo(&value)); return winrt::Windows::Storage::Streams::IBuffer{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::ServiceInfo(winrt::Windows::Storage::Streams::IBuffer const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->put_ServiceInfo(*(void**)(&value))); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::AutoAcceptSession() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->get_AutoAcceptSession(&value)); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::AutoAcceptSession(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->put_AutoAcceptSession(value)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::PreferGroupOwnerMode() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->get_PreferGroupOwnerMode(&value)); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::PreferGroupOwnerMode(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->put_PreferGroupOwnerMode(value)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::PreferredConfigurationMethods() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->get_PreferredConfigurationMethods(&value)); return winrt::Windows::Foundation::Collections::IVector{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::ServiceStatus() const { winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceStatus value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->get_ServiceStatus(reinterpret_cast(&value))); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::ServiceStatus(winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceStatus const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->put_ServiceStatus(static_cast(value))); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::CustomServiceStatusCode() const { uint32_t value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->get_CustomServiceStatusCode(&value)); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::CustomServiceStatusCode(uint32_t value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->put_CustomServiceStatusCode(value)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::DeferredSessionInfo() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->get_DeferredSessionInfo(&value)); return winrt::Windows::Storage::Streams::IBuffer{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::DeferredSessionInfo(winrt::Windows::Storage::Streams::IBuffer const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->put_DeferredSessionInfo(*(void**)(&value))); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::AdvertisementStatus() const { winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceAdvertisementStatus value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->get_AdvertisementStatus(reinterpret_cast(&value))); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::ServiceError() const { winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceError value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->get_ServiceError(reinterpret_cast(&value))); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::SessionRequested(winrt::Windows::Foundation::TypedEventHandler const& handler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->add_SessionRequested(*(void**)(&handler), put_abi(token))); return token; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::SessionRequested(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& handler) const { return impl::make_event_revoker(this, SessionRequested(handler)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::SessionRequested(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->remove_SessionRequested(impl::bind_in(token)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::AutoAcceptSessionConnected(winrt::Windows::Foundation::TypedEventHandler const& handler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->add_AutoAcceptSessionConnected(*(void**)(&handler), put_abi(token))); return token; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::AutoAcceptSessionConnected(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& handler) const { return impl::make_event_revoker(this, AutoAcceptSessionConnected(handler)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::AutoAcceptSessionConnected(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->remove_AutoAcceptSessionConnected(impl::bind_in(token)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::AdvertisementStatusChanged(winrt::Windows::Foundation::TypedEventHandler const& handler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->add_AdvertisementStatusChanged(*(void**)(&handler), put_abi(token))); return token; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::AdvertisementStatusChanged(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& handler) const { return impl::make_event_revoker(this, AdvertisementStatusChanged(handler)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::AdvertisementStatusChanged(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->remove_AdvertisementStatusChanged(impl::bind_in(token)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::ConnectAsync(winrt::Windows::Devices::Enumeration::DeviceInformation const& deviceInfo) const { void* result{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->ConnectAsync(*(void**)(&deviceInfo), &result)); return winrt::Windows::Foundation::IAsyncOperation{ result, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::ConnectAsync(winrt::Windows::Devices::Enumeration::DeviceInformation const& deviceInfo, param::hstring const& pin) const { void* result{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->ConnectAsyncWithPin(*(void**)(&deviceInfo), *(void**)(&pin), &result)); return winrt::Windows::Foundation::IAsyncOperation{ result, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::Start() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->Start()); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiser::Stop() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiser)->Stop()); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAdvertiserFactory::CreateWiFiDirectServiceAdvertiser(param::hstring const& serviceName) const { void* result{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAdvertiserFactory)->CreateWiFiDirectServiceAdvertiser(*(void**)(&serviceName), &result)); return winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceAdvertiser{ result, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAutoAcceptSessionConnectedEventArgs::Session() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAutoAcceptSessionConnectedEventArgs)->get_Session(&value)); return winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceSession{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceAutoAcceptSessionConnectedEventArgs::SessionInfo() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceAutoAcceptSessionConnectedEventArgs)->get_SessionInfo(&value)); return winrt::Windows::Storage::Streams::IBuffer{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceProvisioningInfo::SelectedConfigurationMethod() const { winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceConfigurationMethod value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceProvisioningInfo)->get_SelectedConfigurationMethod(reinterpret_cast(&value))); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceProvisioningInfo::IsGroupFormationNeeded() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceProvisioningInfo)->get_IsGroupFormationNeeded(&value)); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceRemotePortAddedEventArgs::EndpointPairs() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceRemotePortAddedEventArgs)->get_EndpointPairs(&value)); return winrt::Windows::Foundation::Collections::IVectorView{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceRemotePortAddedEventArgs::Protocol() const { winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceIPProtocol value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceRemotePortAddedEventArgs)->get_Protocol(reinterpret_cast(&value))); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::ServiceName() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->get_ServiceName(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::Status() const { winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceSessionStatus value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->get_Status(reinterpret_cast(&value))); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::ErrorStatus() const { winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceSessionErrorStatus value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->get_ErrorStatus(reinterpret_cast(&value))); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::SessionId() const { uint32_t value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->get_SessionId(&value)); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::AdvertisementId() const { uint32_t value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->get_AdvertisementId(&value)); return value; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::ServiceAddress() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->get_ServiceAddress(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::SessionAddress() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->get_SessionAddress(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::GetConnectionEndpointPairs() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->GetConnectionEndpointPairs(&value)); return winrt::Windows::Foundation::Collections::IVectorView{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::SessionStatusChanged(winrt::Windows::Foundation::TypedEventHandler const& handler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->add_SessionStatusChanged(*(void**)(&handler), put_abi(token))); return token; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::SessionStatusChanged(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& handler) const { return impl::make_event_revoker(this, SessionStatusChanged(handler)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::SessionStatusChanged(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->remove_SessionStatusChanged(impl::bind_in(token)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::AddStreamSocketListenerAsync(winrt::Windows::Networking::Sockets::StreamSocketListener const& value) const { void* result{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->AddStreamSocketListenerAsync(*(void**)(&value), &result)); return winrt::Windows::Foundation::IAsyncAction{ result, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::AddDatagramSocketAsync(winrt::Windows::Networking::Sockets::DatagramSocket const& value) const { void* result{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->AddDatagramSocketAsync(*(void**)(&value), &result)); return winrt::Windows::Foundation::IAsyncAction{ result, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::RemotePortAdded(winrt::Windows::Foundation::TypedEventHandler const& handler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->add_RemotePortAdded(*(void**)(&handler), put_abi(token))); return token; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::RemotePortAdded(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& handler) const { return impl::make_event_revoker(this, RemotePortAdded(handler)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSession::RemotePortAdded(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSession)->remove_RemotePortAdded(impl::bind_in(token)); } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSessionDeferredEventArgs::DeferredSessionInfo() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSessionDeferredEventArgs)->get_DeferredSessionInfo(&value)); return winrt::Windows::Storage::Streams::IBuffer{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSessionRequest::DeviceInformation() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSessionRequest)->get_DeviceInformation(&value)); return winrt::Windows::Devices::Enumeration::DeviceInformation{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSessionRequest::ProvisioningInfo() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSessionRequest)->get_ProvisioningInfo(&value)); return winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceProvisioningInfo{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSessionRequest::SessionInfo() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSessionRequest)->get_SessionInfo(&value)); return winrt::Windows::Storage::Streams::IBuffer{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceSessionRequestedEventArgs::GetSessionRequest() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceSessionRequestedEventArgs)->GetSessionRequest(&value)); return winrt::Windows::Devices::WiFiDirect::Services::WiFiDirectServiceSessionRequest{ value, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceStatics::GetSelector(param::hstring const& serviceName) const { void* serviceSelector{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceStatics)->GetSelector(*(void**)(&serviceName), &serviceSelector)); return hstring{ serviceSelector, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceStatics::GetSelector(param::hstring const& serviceName, winrt::Windows::Storage::Streams::IBuffer const& serviceInfoFilter) const { void* serviceSelector{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceStatics)->GetSelectorWithFilter(*(void**)(&serviceName), *(void**)(&serviceInfoFilter), &serviceSelector)); return hstring{ serviceSelector, take_ownership_from_abi }; } template auto consume_Windows_Devices_WiFiDirect_Services_IWiFiDirectServiceStatics::FromIdAsync(param::hstring const& deviceId) const { void* asyncOp{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Devices::WiFiDirect::Services::IWiFiDirectServiceStatics)->FromIdAsync(*(void**)(&deviceId), &asyncOp)); return winrt::Windows::Foundation::IAsyncOperation{ asyncOp, take_ownership_from_abi }; } #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_RemoteServiceInfo(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().RemoteServiceInfo()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_SupportedConfigurationMethods(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().SupportedConfigurationMethods()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_PreferGroupOwnerMode(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().PreferGroupOwnerMode()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_PreferGroupOwnerMode(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().PreferGroupOwnerMode(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_SessionInfo(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().SessionInfo()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_SessionInfo(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().SessionInfo(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ServiceError(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ServiceError()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall add_SessionDeferred(void* handler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().SessionDeferred(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_SessionDeferred(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().SessionDeferred(*reinterpret_cast(&token)); return 0; } int32_t __stdcall GetProvisioningInfoAsync(int32_t selectedConfigurationMethod, void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from>(this->shim().GetProvisioningInfoAsync(*reinterpret_cast(&selectedConfigurationMethod))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ConnectAsync(void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from>(this->shim().ConnectAsync()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ConnectAsyncWithPin(void* pin, void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from>(this->shim().ConnectAsync(*reinterpret_cast(&pin))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_ServiceName(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ServiceName()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ServiceNamePrefixes(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().ServiceNamePrefixes()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ServiceInfo(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ServiceInfo()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_ServiceInfo(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ServiceInfo(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_AutoAcceptSession(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().AutoAcceptSession()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_AutoAcceptSession(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().AutoAcceptSession(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_PreferGroupOwnerMode(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().PreferGroupOwnerMode()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_PreferGroupOwnerMode(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().PreferGroupOwnerMode(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_PreferredConfigurationMethods(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().PreferredConfigurationMethods()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ServiceStatus(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ServiceStatus()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_ServiceStatus(int32_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ServiceStatus(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_CustomServiceStatusCode(uint32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().CustomServiceStatusCode()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_CustomServiceStatusCode(uint32_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().CustomServiceStatusCode(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_DeferredSessionInfo(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().DeferredSessionInfo()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_DeferredSessionInfo(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().DeferredSessionInfo(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_AdvertisementStatus(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().AdvertisementStatus()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ServiceError(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ServiceError()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall add_SessionRequested(void* handler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().SessionRequested(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_SessionRequested(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().SessionRequested(*reinterpret_cast(&token)); return 0; } int32_t __stdcall add_AutoAcceptSessionConnected(void* handler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().AutoAcceptSessionConnected(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_AutoAcceptSessionConnected(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().AutoAcceptSessionConnected(*reinterpret_cast(&token)); return 0; } int32_t __stdcall add_AdvertisementStatusChanged(void* handler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().AdvertisementStatusChanged(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_AdvertisementStatusChanged(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().AdvertisementStatusChanged(*reinterpret_cast(&token)); return 0; } int32_t __stdcall ConnectAsync(void* deviceInfo, void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from>(this->shim().ConnectAsync(*reinterpret_cast(&deviceInfo))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ConnectAsyncWithPin(void* deviceInfo, void* pin, void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from>(this->shim().ConnectAsync(*reinterpret_cast(&deviceInfo), *reinterpret_cast(&pin))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall Start() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Start(); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall Stop() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Stop(); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall CreateWiFiDirectServiceAdvertiser(void* serviceName, void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from(this->shim().CreateWiFiDirectServiceAdvertiser(*reinterpret_cast(&serviceName))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Session(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Session()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_SessionInfo(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().SessionInfo()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_SelectedConfigurationMethod(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().SelectedConfigurationMethod()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsGroupFormationNeeded(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsGroupFormationNeeded()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_EndpointPairs(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().EndpointPairs()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Protocol(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Protocol()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_ServiceName(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ServiceName()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Status(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Status()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ErrorStatus(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ErrorStatus()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_SessionId(uint32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().SessionId()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_AdvertisementId(uint32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().AdvertisementId()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ServiceAddress(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ServiceAddress()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_SessionAddress(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().SessionAddress()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall GetConnectionEndpointPairs(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().GetConnectionEndpointPairs()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall add_SessionStatusChanged(void* handler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().SessionStatusChanged(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_SessionStatusChanged(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().SessionStatusChanged(*reinterpret_cast(&token)); return 0; } int32_t __stdcall AddStreamSocketListenerAsync(void* value, void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from(this->shim().AddStreamSocketListenerAsync(*reinterpret_cast(&value))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall AddDatagramSocketAsync(void* value, void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from(this->shim().AddDatagramSocketAsync(*reinterpret_cast(&value))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall add_RemotePortAdded(void* handler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().RemotePortAdded(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_RemotePortAdded(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().RemotePortAdded(*reinterpret_cast(&token)); return 0; } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_DeferredSessionInfo(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().DeferredSessionInfo()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_DeviceInformation(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().DeviceInformation()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ProvisioningInfo(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ProvisioningInfo()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_SessionInfo(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().SessionInfo()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall GetSessionRequest(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().GetSessionRequest()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall GetSelector(void* serviceName, void** serviceSelector) noexcept final try { clear_abi(serviceSelector); typename D::abi_guard guard(this->shim()); *serviceSelector = detach_from(this->shim().GetSelector(*reinterpret_cast(&serviceName))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall GetSelectorWithFilter(void* serviceName, void* serviceInfoFilter, void** serviceSelector) noexcept final try { clear_abi(serviceSelector); typename D::abi_guard guard(this->shim()); *serviceSelector = detach_from(this->shim().GetSelector(*reinterpret_cast(&serviceName), *reinterpret_cast(&serviceInfoFilter))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall FromIdAsync(void* deviceId, void** asyncOp) noexcept final try { clear_abi(asyncOp); typename D::abi_guard guard(this->shim()); *asyncOp = detach_from>(this->shim().FromIdAsync(*reinterpret_cast(&deviceId))); return 0; } catch (...) { return to_hresult(); } }; #endif } WINRT_EXPORT namespace winrt::Windows::Devices::WiFiDirect::Services { inline auto WiFiDirectService::GetSelector(param::hstring const& serviceName) { return impl::call_factory([&](IWiFiDirectServiceStatics const& f) { return f.GetSelector(serviceName); }); } inline auto WiFiDirectService::GetSelector(param::hstring const& serviceName, winrt::Windows::Storage::Streams::IBuffer const& serviceInfoFilter) { return impl::call_factory([&](IWiFiDirectServiceStatics const& f) { return f.GetSelector(serviceName, serviceInfoFilter); }); } inline auto WiFiDirectService::FromIdAsync(param::hstring const& deviceId) { return impl::call_factory([&](IWiFiDirectServiceStatics const& f) { return f.FromIdAsync(deviceId); }); } inline WiFiDirectServiceAdvertiser::WiFiDirectServiceAdvertiser(param::hstring const& serviceName) : WiFiDirectServiceAdvertiser(impl::call_factory([&](IWiFiDirectServiceAdvertiserFactory const& f) { return f.CreateWiFiDirectServiceAdvertiser(serviceName); })) { } } 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 {}; #endif #ifdef __cpp_lib_format #endif } #endif