TcpClientChannel 생성자

정의

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

오버로드

Name Description
TcpClientChannel()

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

TcpClientChannel(IDictionary, IClientChannelSinkProvider)

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

TcpClientChannel(String, IClientChannelSinkProvider)

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

TcpClientChannel()

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

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

예제

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

// Set up a client channel.
TcpClientChannel^ clientChannel = gcnew TcpClientChannel;
ChannelServices::RegisterChannel( clientChannel );
// Set up a client channel.
TcpClientChannel clientChannel = new TcpClientChannel();
ChannelServices.RegisterChannel(clientChannel);

설명

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

적용 대상

TcpClientChannel(IDictionary, IClientChannelSinkProvider)

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

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

매개 변수

properties
IDictionary

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

sinkProvider
IClientChannelSinkProvider

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

예외

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

예제

다음 코드 예제에서는이 생성자를 사용 하 여 특정 구성 속성을 사용 하 여 개체를 TcpClientChannel 만드는 방법을 보여 있습니다.

// Specify client channel properties.
IDictionary^ dict = gcnew Hashtable;
dict[ "port" ] = 9090;
dict[ "impersonationLevel" ] = "Identify";
dict[ "authenticationPolicy" ] = "AuthPolicy, Policy";

// Set up a client channel.
TcpClientChannel^ clientChannel = gcnew TcpClientChannel( dict, nullptr );
ChannelServices::RegisterChannel( clientChannel, false );
// Specify client channel properties.
IDictionary dict = new Hashtable();
dict["port"] = 9090;
dict["impersonationLevel"] = "Identify";
dict["authenticationPolicy"] = "AuthPolicy, Policy";

// Set up a client channel.
TcpClientChannel clientChannel = new TcpClientChannel(dict, null);
ChannelServices.RegisterChannel(clientChannel, false);

설명

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

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

추가 정보

적용 대상

TcpClientChannel(String, IClientChannelSinkProvider)

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

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

매개 변수

name
String

채널의 이름입니다.

sinkProvider
IClientChannelSinkProvider

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

예제

다음 코드 예제에서는 TcpClientChannel.

// Create the channel.
TcpClientChannel^ clientChannel = gcnew TcpClientChannel( "Client",nullptr );
// Create the channel.
TcpClientChannel clientChannel = new TcpClientChannel("Client", null);

설명

이 생성자는 매개 변수를 ChannelName 사용하여 name 속성을 설정합니다. 둘 이상의 채널을 등록하려면 각 채널에 고유한 이름이 있어야 합니다.

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

적용 대상