RouteServiceClient Constructor

 

Initializes a new instance of the RouteServiceClient Class.

Syntax

public RouteServiceClient()
Public Sub New

Syntax

public RouteServiceClient(string endpointConfigurationName)
Public Sub New(ByVal endpointConfigurationName As String)

Syntax

public RouteServiceClient(string endpointConfigurationName, string remoteAddress)
Public Sub New(ByVal endpointConfigurationName As String, ByVal remoteAddress As String)

Syntax

public RouteServiceClient(string endpointConfigurationName, System.ServiceModel.EndpointAddress remoteAddress)
Public Sub New(ByVal endpointConfigurationName As String, ByVal remoteAddress As System.ServiceModel.EndpointAddress)

Syntax

public RouteServiceClient(System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress)
Public Sub New(ByVal binding As System.ServiceModel.Channels.Binding, ByVal remoteAddress As System.ServiceModel.EndpointAddress)

Parameters

endpointConfigurationName

The endpoint for a service that allows clients to find and communicate with the service.

binding

The binding with which to make calls to the service.

remoteAddress

The address of the service endpoint.

Remarks

The Route service provides endpoints for Basic HTTP and Binary over HTTP configurations. When you create a proxy for your application, references to both endpoints are added to your application. Therefore, you must specify the endpoint you want to use. To specify the endpoint, use the following endpoint configuration names.

Endpoint Configuration Type

Endpoint Configuration Name

Basic HTTP

BasicHttpBinding_IRouteService

Binary over HTTP

CustomBinding_IRouteService

Example

Create a RouteServiceClient object that uses the binary over HTTP endpoint.

RouteService.RouteServiceClient RouteService = new RouteService.RouteServiceClient("CustomBinding_IRouteService");
Dim RouteServiceInstance As New RouteService.RouteServiceClient("BasicHttpBinding_IRouteService")

See Also

System.ServiceModel.ClientBase.ClientBase(TChannel) Constructor