다음을 통해 공유


HttpClientChannel 생성자

정의

HttpClientChannel 클래스의 새 인스턴스를 초기화합니다.

오버로드

Name Description
HttpClientChannel()

HttpClientChannel 클래스의 새 인스턴스를 초기화합니다.

HttpClientChannel(IDictionary, IClientChannelSinkProvider)

지정된 구성 속성 및 싱크를 HttpClientChannel 사용하여 클래스의 새 인스턴스를 초기화합니다.

HttpClientChannel(String, IClientChannelSinkProvider)

지정된 이름과 싱크를 사용하여 클래스의 HttpClientChannel 새 인스턴스를 초기화합니다.

HttpClientChannel()

HttpClientChannel 클래스의 새 인스턴스를 초기화합니다.

public:
 HttpClientChannel();
public HttpClientChannel();
Public Sub New ()

설명

이 생성자가 반환하는 인스턴스의 HttpClientChannel 구성 속성은 모두 기본값으로 설정됩니다.

적용 대상

HttpClientChannel(IDictionary, IClientChannelSinkProvider)

지정된 구성 속성 및 싱크를 HttpClientChannel 사용하여 클래스의 새 인스턴스를 초기화합니다.

public:
 HttpClientChannel(System::Collections::IDictionary ^ properties, System::Runtime::Remoting::Channels::IClientChannelSinkProvider ^ sinkProvider);
public HttpClientChannel(System.Collections.IDictionary properties, System.Runtime.Remoting.Channels.IClientChannelSinkProvider sinkProvider);
new System.Runtime.Remoting.Channels.Http.HttpClientChannel : System.Collections.IDictionary * System.Runtime.Remoting.Channels.IClientChannelSinkProvider -> System.Runtime.Remoting.Channels.Http.HttpClientChannel
Public Sub New (properties As IDictionary, sinkProvider As IClientChannelSinkProvider)

매개 변수

properties
IDictionary

IDictionary 채널에서 사용할 구성 속성의 값을 지정하는 컬렉션입니다.

sinkProvider
IClientChannelSinkProvider

IClientChannelSinkProvider 채널에서 사용할 구현입니다.

예외

구성 속성의 형식이 잘못되었습니다.

예제

다음 코드 예제에서는이 생성자를 사용 하는 방법을 보여 있습니다.

// Create a client channel.
System::Collections::Hashtable^ properties = gcnew System::Collections::Hashtable;
properties->default[ L"port" ] = 9090;
IClientChannelSinkProvider^ sinkProvider = nullptr;
HttpClientChannel^ clientChannel = gcnew HttpClientChannel( properties,sinkProvider );
// Create a client channel.
System.Collections.Hashtable properties =
    new System.Collections.Hashtable();
properties["port"] = 9090;
IClientChannelSinkProvider sinkProvider = null;
HttpClientChannel clientChannel = new HttpClientChannel(
    properties, sinkProvider);

설명

채널 구성 속성에 대한 자세한 내용은 채널 및 포맷터 구성 속성을 참조하세요.

싱크 기능이 필요하지 않은 경우 매개 변수nullsinkProvider .로 설정합니다.

추가 정보

적용 대상

HttpClientChannel(String, IClientChannelSinkProvider)

지정된 이름과 싱크를 사용하여 클래스의 HttpClientChannel 새 인스턴스를 초기화합니다.

public:
 HttpClientChannel(System::String ^ name, System::Runtime::Remoting::Channels::IClientChannelSinkProvider ^ sinkProvider);
public HttpClientChannel(string name, System.Runtime.Remoting.Channels.IClientChannelSinkProvider sinkProvider);
new System.Runtime.Remoting.Channels.Http.HttpClientChannel : string * System.Runtime.Remoting.Channels.IClientChannelSinkProvider -> System.Runtime.Remoting.Channels.Http.HttpClientChannel
Public Sub New (name As String, sinkProvider As IClientChannelSinkProvider)

매개 변수

name
String

의 새 인스턴스 이름입니다 HttpClientChannel.

sinkProvider
IClientChannelSinkProvider

IClientChannelSinkProvider 채널에서 사용할 수 있는 개체입니다.

예제

다음 코드 예제에서는이 생성자를 사용 하는 방법을 보여 있습니다.

// Create a client channel.
String^ name = L"RemotingClient";
IClientChannelSinkProvider^ sinkProvider = nullptr;
HttpClientChannel^ clientChannel = gcnew HttpClientChannel( name,sinkProvider );
// Create a client channel.
string name = "RemotingClient";
IClientChannelSinkProvider sinkProvider = null;
HttpClientChannel clientChannel = new HttpClientChannel(name,
    sinkProvider);

설명

이 생성자는 매개 변수를 ChannelName 사용하여 name 속성을 설정합니다.

적용 대상