Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

WCF: How do I get the list of endpoints from ServiceHost?

Tags:

.net

wcf

.net-3.0

I can add endpoints using ServiceHost.AddServiceEndpoint. How do I get that list of endpoints back out?

like image 771
Jonathan Allen Avatar asked Mar 04 '09 23:03

Jonathan Allen


People also ask

Where we define endpoints in WCF?

Endpoints provide clients access to the functionality offered by a WCF service. Each endpoint consists of four properties: An address that indicates where the endpoint can be found. A binding that specifies how a client can communicate with the endpoint.

How many types of endpoints are there in WCF?

Endpoints in WCF End point consists of three components.

What is EndpointAddress?

The endpoint address is represented by the EndpointAddress class, which contains a Uniform Resource Identifier (URI) that represents the address of the service, an Identity, which represents the security identity of the service, and a collection of optional Headers.


1 Answers

Use host.Description.Endpoints

like image 68
Brian Avatar answered Oct 19 '22 19:10

Brian