ServiceHost.AddServiceEndpoint 메서드

정의

호스트된 서비스에 서비스 엔드포인트를 추가합니다.

오버로드

Name Description
AddServiceEndpoint(Type, Binding, String)

지정된 계약, 바인딩 및 엔드포인트 주소를 사용하여 호스트된 서비스에 서비스 엔드포인트를 추가합니다.

AddServiceEndpoint(Type, Binding, Uri)

엔드포인트 주소를 포함하는 지정된 계약, 바인딩 및 URI를 사용하여 호스트된 서비스에 서비스 엔드포인트를 추가합니다.

AddServiceEndpoint(Type, Binding, String, Uri)

지정된 계약, 바인딩, 엔드포인트 주소 및 서비스가 수신 대기하는 URI를 사용하여 호스트된 서비스에 서비스 엔드포인트를 추가합니다.

AddServiceEndpoint(Type, Binding, Uri, Uri)

지정된 계약, 바인딩, 엔드포인트 주소가 포함된 URI 및 서비스가 수신 대기하는 URI를 사용하여 호스트된 서비스에 서비스 엔드포인트를 추가합니다.

AddServiceEndpoint(Type, Binding, String)

지정된 계약, 바인딩 및 엔드포인트 주소를 사용하여 호스트된 서비스에 서비스 엔드포인트를 추가합니다.

public:
 System::ServiceModel::Description::ServiceEndpoint ^ AddServiceEndpoint(Type ^ implementedContract, System::ServiceModel::Channels::Binding ^ binding, System::String ^ address);
public System.ServiceModel.Description.ServiceEndpoint AddServiceEndpoint(Type implementedContract, System.ServiceModel.Channels.Binding binding, string address);
override this.AddServiceEndpoint : Type * System.ServiceModel.Channels.Binding * string -> System.ServiceModel.Description.ServiceEndpoint
Public Function AddServiceEndpoint (implementedContract As Type, binding As Binding, address As String) As ServiceEndpoint

매개 변수

implementedContract
Type

Type 추가된 엔드포인트에 대한 계약의 수입니다.

binding
Binding

추가된 엔드포인트의 경우입니다 Binding .

address
String

추가된 엔드포인트의 주소입니다.

반품

ServiceEndpoint 호스트된 서비스에 추가되었습니다.

예외

implementedContract 또는 bindingaddress 입니다 null.

예제

WSHttpBinding binding = new WSHttpBinding();
serviceHost.AddServiceEndpoint(typeof(ICalculator), binding, "http://localhost:8000/servicemodelsamples/service/basic");
Dim binding As BasicHttpBinding = New BasicHttpBinding()
serviceHost.AddServiceEndpoint(GetType(ICalculator), binding, "http://localhost:8000/servicemodelsamples/service/basic")

적용 대상

AddServiceEndpoint(Type, Binding, Uri)

엔드포인트 주소를 포함하는 지정된 계약, 바인딩 및 URI를 사용하여 호스트된 서비스에 서비스 엔드포인트를 추가합니다.

public:
 System::ServiceModel::Description::ServiceEndpoint ^ AddServiceEndpoint(Type ^ implementedContract, System::ServiceModel::Channels::Binding ^ binding, Uri ^ address);
public System.ServiceModel.Description.ServiceEndpoint AddServiceEndpoint(Type implementedContract, System.ServiceModel.Channels.Binding binding, Uri address);
override this.AddServiceEndpoint : Type * System.ServiceModel.Channels.Binding * Uri -> System.ServiceModel.Description.ServiceEndpoint
Public Function AddServiceEndpoint (implementedContract As Type, binding As Binding, address As Uri) As ServiceEndpoint

매개 변수

implementedContract
Type

Type 추가된 엔드포인트에 대한 계약의 수입니다.

binding
Binding

추가된 엔드포인트의 경우입니다 Binding .

address
Uri

Uri 추가된 엔드포인트의 주소가 들어 있는 항목입니다.

반품

ServiceEndpoint 호스트된 서비스에 추가되었습니다.

예외

implementedContract 또는 bindingaddress 입니다 null.

예제

BasicHttpBinding binding = new BasicHttpBinding();
Uri address = new Uri("http://localhost:8000/servicemodelsamples/service/basic");
serviceHost.AddServiceEndpoint(typeof(ICalculator), binding, address);
Dim binding As BasicHttpBinding = New BasicHttpBinding()
Dim address As Uri = New Uri("http://localhost:8000/servicemodelsamples/service/basic")
serviceHost.AddServiceEndpoint(GetType(ICalculator), binding, address)

적용 대상

AddServiceEndpoint(Type, Binding, String, Uri)

지정된 계약, 바인딩, 엔드포인트 주소 및 서비스가 수신 대기하는 URI를 사용하여 호스트된 서비스에 서비스 엔드포인트를 추가합니다.

public:
 System::ServiceModel::Description::ServiceEndpoint ^ AddServiceEndpoint(Type ^ implementedContract, System::ServiceModel::Channels::Binding ^ binding, System::String ^ address, Uri ^ listenUri);
public System.ServiceModel.Description.ServiceEndpoint AddServiceEndpoint(Type implementedContract, System.ServiceModel.Channels.Binding binding, string address, Uri listenUri);
override this.AddServiceEndpoint : Type * System.ServiceModel.Channels.Binding * string * Uri -> System.ServiceModel.Description.ServiceEndpoint
Public Function AddServiceEndpoint (implementedContract As Type, binding As Binding, address As String, listenUri As Uri) As ServiceEndpoint

매개 변수

implementedContract
Type

Type 추가된 엔드포인트에 대한 계약의 수입니다.

binding
Binding

추가된 엔드포인트의 경우입니다 Binding .

address
String

서비스의 엔드포인트 주소입니다.

listenUri
Uri

Uri 서비스 엔드포인트가 수신 대기할 수 있는 기능입니다.

반품

ServiceEndpoint 호스트된 서비스에 추가되었습니다.

예외

implementedContract 또는 bindingaddress 입니다 null.

예제

BasicHttpBinding binding = new BasicHttpBinding();
Uri listenUri = new Uri("http://localhost:8000/MyListenUri");
string address = "http://localhost:8000/servicemodelsamples/service2";
serviceHost.AddServiceEndpoint(typeof(ICalculator), binding, address, listenUri);
Dim binding As BasicHttpBinding = New BasicHttpBinding()
Dim listenUri As Uri = New Uri("http://localhost:8000/MyListenUri")
Dim address As String = "http://localhost:8000/servicemodelsamples/service/basic"
serviceHost.AddServiceEndpoint(GetType(ICalculator), binding, address, listenUri)

설명

지정된 동일한 URI에서 수신 대기해야 하는 여러 엔드포인트가 있는 경우 이 버전의 메서드를 사용합니다.

적용 대상

AddServiceEndpoint(Type, Binding, Uri, Uri)

지정된 계약, 바인딩, 엔드포인트 주소가 포함된 URI 및 서비스가 수신 대기하는 URI를 사용하여 호스트된 서비스에 서비스 엔드포인트를 추가합니다.

public:
 System::ServiceModel::Description::ServiceEndpoint ^ AddServiceEndpoint(Type ^ implementedContract, System::ServiceModel::Channels::Binding ^ binding, Uri ^ address, Uri ^ listenUri);
public System.ServiceModel.Description.ServiceEndpoint AddServiceEndpoint(Type implementedContract, System.ServiceModel.Channels.Binding binding, Uri address, Uri listenUri);
override this.AddServiceEndpoint : Type * System.ServiceModel.Channels.Binding * Uri * Uri -> System.ServiceModel.Description.ServiceEndpoint
Public Function AddServiceEndpoint (implementedContract As Type, binding As Binding, address As Uri, listenUri As Uri) As ServiceEndpoint

매개 변수

implementedContract
Type

Type 추가된 엔드포인트에 대한 계약의 수입니다.

binding
Binding

추가된 엔드포인트의 경우입니다 Binding .

address
Uri

Uri 추가된 엔드포인트의 주소가 들어 있는 항목입니다.

listenUri
Uri

Uri 서비스 엔드포인트가 수신 대기할 수 있는 기능입니다.

반품

ServiceEndpoint 호스트된 서비스에 추가되었습니다.

예외

implementedContract 또는 bindingaddress 입니다 null.

계약이 초기화되지 않았거나 계약 키를 찾을 수 없습니다.

예제

BasicHttpBinding binding = new BasicHttpBinding();
Uri listenUri = new Uri("http://localhost:8000/MyListenUri");
Uri address = new Uri("http://localhost:8000/servicemodelsamples/service3");
serviceHost.AddServiceEndpoint(typeof(ICalculator), binding, address, listenUri);
Dim binding As BasicHttpBinding = New BasicHttpBinding()
Dim listenUri As Uri = New Uri("http://localhost:8000/MyListenUri")
Dim address As Uri = New Uri("http://localhost:8000/servicemodelsamples/service/basic")
serviceHost.AddServiceEndpoint(GetType(ICalculator), binding, address, listenUri)

설명

지정된 동일한 URI에서 수신 대기해야 하는 여러 엔드포인트가 있는 경우 이 버전의 메서드를 사용합니다.

적용 대상