Share via


DataServiceContext.TryGetUri(Object, Uri) 메서드

정의

지정된 엔터티와 연결된 정식 URI(사용 가능한 경우)를 검색합니다.

public:
 bool TryGetUri(System::Object ^ entity, [Runtime::InteropServices::Out] Uri ^ % identity);
public bool TryGetUri (object entity, out Uri identity);
member this.TryGetUri : obj * Uri -> bool
Public Function TryGetUri (entity As Object, ByRef identity As Uri) As Boolean

매개 변수

entity
Object

identity로 식별된 엔터티입니다.

identity
Uri

엔터티의 URI입니다.

반환

정식 URI가 출력 매개 변수에 반환되는 경우 true를 반환합니다. 지정된 엔터티가 DataServiceContext에서 추적되지 않거나 추가된 상태인 경우 URI를 사용할 수 없으며 false가 반환됩니다.

예외

entitynull일 경우

설명

상태의 개체에는 Added 아직 URI가 없습니다.

적용 대상