winrt::xaml_typename 함수 템플릿(C++/WinRT)

Windows::UI::Xaml::Interop::TypeName 개체 형식으로 Windows 런타임 형식의 형식 이름을 반환하는 도우미 함수입니다. GetRuntimeClassName 함수도 참조하세요.

구문

template <typename T>
inline winrt::Windows::UI::Xaml::Interop::TypeName xaml_typename();

템플릿 매개 변수

typename TWindows 런타임 클래스 형식입니다.

반환 값

형식을 나타내는 Windows::UI::Xaml::Interop::TypeName 개체입니다.

예제

// App.cpp
void App::OnLaunched(LaunchActivatedEventArgs const& e)
{
    Frame rootFrame{ nullptr };
    auto content = Window::Current().Content();
    if (content) rootFrame = content.try_as<Frame>();
    ...
    rootFrame.Navigate(xaml_typename<Bookstore::MainPage>(), box_value(e.Arguments()));
    ...
}

요구 사항

지원되는 최소 SDK: Windows SDK 버전 10.0.17134.0(Windows 10, 버전 1803)

네임스페이스: winrt

헤더: %WindowsSdkDir%IncludeWindowsTargetPlatformVersion<>\cppwinrt\winrt\Windows. UI. Xaml.Interop.h(기본적으로 포함되지 않음)

참고 항목