ResourceMap.GetValue 메서드

정의

오버로드

GetValue(String)

기본 컨텍스트 내에서 리소스 식별자에 의해 지정된 리소스에 가장 적합한 후보를 반환합니다.

GetValue(String, ResourceContext)

제공된 컨텍스트에 대한 리소스 식별자에 의해 지정된 리소스에 가장 적합한 후보를 반환합니다.

GetValue(String)

기본 컨텍스트 내에서 리소스 식별자에 의해 지정된 리소스에 가장 적합한 후보를 반환합니다.

public:
 virtual ResourceCandidate ^ GetValue(Platform::String ^ resource) = GetValue;
/// [Windows.Foundation.Metadata.Overload("GetValue")]
ResourceCandidate GetValue(winrt::hstring const& resource);
[Windows.Foundation.Metadata.Overload("GetValue")]
public ResourceCandidate GetValue(string resource);
function getValue(resource)
Public Function GetValue (resource As String) As ResourceCandidate

매개 변수

resource
String

Platform::String

winrt::hstring

이름 또는 참조로 지정된 리소스 식별자입니다. 자세한 내용은 ResourceMap 클래스에 대한 설명을 참조하세요.

반환

가장 적합한 후보를 설명하는 ResourceCandidate 입니다.

특성

적용 대상

GetValue(String, ResourceContext)

제공된 컨텍스트에 대한 리소스 식별자에 의해 지정된 리소스에 가장 적합한 후보를 반환합니다.

public:
 virtual ResourceCandidate ^ GetValue(Platform::String ^ resource, ResourceContext ^ context) = GetValue;
/// [Windows.Foundation.Metadata.Overload("GetValueWithContext")]
ResourceCandidate GetValue(winrt::hstring const& resource, ResourceContext const& context);
[Windows.Foundation.Metadata.Overload("GetValueWithContext")]
public ResourceCandidate GetValue(string resource, ResourceContext context);
function getValue(resource, context)
Public Function GetValue (resource As String, context As ResourceContext) As ResourceCandidate

매개 변수

resource
String

Platform::String

winrt::hstring

이름 또는 참조로 지정된 리소스입니다. 자세한 내용은 ResourceMap 클래스에 대한 설명을 참조하세요.

context
ResourceContext

가장 적합한 후보를 선택할 컨텍스트입니다.

반환

가장 적합한 후보를 설명하는 ResourceCandidate 입니다.

특성

설명

일부 리소스는 표시될 보기의 규모에 따라 로드되며, 앱 내의 다른 보기는 크기가 다른 다른 디바이스에 표시될 수 있습니다. 크기 조정은 보기별 특성입니다.

GetValue 메서드는 런타임 컨텍스트와 관련하여 지정된 리소스에 가장 적합한 후보를 선택하므로 ResourceContext의 크기 조정 한정자는 연결된 뷰에 따라 달라지므로 리소스가 사용될 뷰에서 가져온 ResourceContext 개체를 사용하여 GetValue를 항상 호출해야 합니다.

적용 대상