AppInstance.FindOrRegisterForKey(String) 메서드
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
플랫폼에 instance 앱을 등록하거나 다른 instance 이 키를 이미 등록한 경우 기존 instance 찾습니다.
public:
static AppInstance ^ FindOrRegisterForKey(Platform::String ^ key);
/// [Windows.Foundation.Metadata.Experimental]
static AppInstance FindOrRegisterForKey(winrt::hstring const& key);
static AppInstance FindOrRegisterForKey(winrt::hstring const& key);
[Windows.Foundation.Metadata.Experimental]
public static AppInstance FindOrRegisterForKey(string key);
public static AppInstance FindOrRegisterForKey(string key);
function findOrRegisterForKey(key)
Public Shared Function FindOrRegisterForKey (key As String) As AppInstance
매개 변수
- key
-
String
Platform::String
winrt::hstring
비어 있지 않은 문자열을 instance 키로 사용합니다.
반환
키를 등록한 첫 번째 앱을 나타내는 앱 instance. 호출자는 해당 instance 현재 instance 여부를 확인할 수 있습니다.
- 특성
설명
Windows OS의 FindOrRegisterInstanceForKey 메서드는 instance 리디렉션과 관련이 있는 반면, Windows App SDK 이 메서드를 사용하면 앱이 어떤 이유로든 키를 등록할 수 있습니다.
앱이 플랫폼에 등록되면 다른 인스턴스가 앱 인스턴스를 쿼리할 때 반환됩니다.
앱 instance 서로 다른 키에 여러 번 등록할 수 있습니다. 시스템 캐시는 instance당 하나의 행을 유지 관리하므로 키를 덮어씁니다.
적용 대상
추가 정보
피드백
https://aka.ms/ContentUserFeedback
출시 예정: 2024년 내내 콘텐츠에 대한 피드백 메커니즘으로 GitHub 문제를 단계적으로 폐지하고 이를 새로운 피드백 시스템으로 바꿀 예정입니다. 자세한 내용은 다음을 참조하세요.다음에 대한 사용자 의견 제출 및 보기