Share via


HttpClientChannel.Parse(String, String) 메서드

정의

지정된 URL에서 채널 URI와 잘 알려진 원격 개체 URI를 추출합니다.

public:
 virtual System::String ^ Parse(System::String ^ url, [Runtime::InteropServices::Out] System::String ^ % objectURI);
public string Parse (string url, out string objectURI);
abstract member Parse : string * string -> string
override this.Parse : string * string -> string
Public Function Parse (url As String, ByRef objectURI As String) As String

매개 변수

url
String

잘 알려진 원격 개체의 URI를 추출할 URL입니다.

objectURI
String

이 메서드가 반환될 때 잘 알려진 원격 개체의 URI를 보유하는 String을 포함합니다. 이 매개 변수는 초기화되지 않은 상태로 전달됩니다.

반환

현재 채널의 URI이거나, 해당 URL이 HTTP URL이 아닌 경우 null입니다.

구현

예제

다음 코드 예제에서는 Parse 메서드를 사용하는 방법을 보여 줍니다. 이 코드 예제는에 대해 제공 된 큰 예제의 일부는 HttpClientChannel 클래스입니다.

// Parse the channel's URI.
String^ objectUrl = L"http://localhost:9090/RemoteObject.rem";
String^ channelUri = clientChannel->Parse( objectUrl,  objectUri );
Console::WriteLine( L"The object URL is {0}.", objectUrl );
Console::WriteLine( L"The object URI is {0}.", objectUri );
Console::WriteLine( L"The channel URI is {0}.", channelUri );
// Parse the channel's URI.
string objectUrl = "http://localhost:9090/RemoteObject.rem";
string channelUri = clientChannel.Parse(objectUrl, out objectUri);
Console.WriteLine("The object URL is {0}.", objectUrl);
Console.WriteLine("The object URI is {0}.", objectUri);
Console.WriteLine("The channel URI is {0}.", channelUri);

적용 대상

추가 정보