public void Dispose()
        {
            if (_client.State != CommunicationState.Closed)
            {
                _client.Close();
            }

            _client = null;
        }
Exemplo n.º 2
0
 private static System.ServiceModel.EndpointAddress GetDefaultEndpointAddress()
 {
     return(DownloadQueueExternalBasicClient.GetEndpointAddress(EndpointConfiguration.BasicHttpBinding_IDownloadQueueExternalBasic));
 }
Exemplo n.º 3
0
 private static System.ServiceModel.Channels.Binding GetDefaultBinding()
 {
     return(DownloadQueueExternalBasicClient.GetBindingForEndpoint(EndpointConfiguration.BasicHttpBinding_IDownloadQueueExternalBasic));
 }
Exemplo n.º 4
0
 public DownloadQueueExternalBasicClient(EndpointConfiguration endpointConfiguration, System.ServiceModel.EndpointAddress remoteAddress) :
     base(DownloadQueueExternalBasicClient.GetBindingForEndpoint(endpointConfiguration), remoteAddress)
 {
     this.Endpoint.Name = endpointConfiguration.ToString();
     ConfigureEndpoint(this.Endpoint, this.ClientCredentials);
 }
Exemplo n.º 5
0
 public DownloadQueueExternalBasicClient(EndpointConfiguration endpointConfiguration) :
     base(DownloadQueueExternalBasicClient.GetBindingForEndpoint(endpointConfiguration), DownloadQueueExternalBasicClient.GetEndpointAddress(endpointConfiguration))
 {
     this.Endpoint.Name = endpointConfiguration.ToString();
     ConfigureEndpoint(this.Endpoint, this.ClientCredentials);
 }
Exemplo n.º 6
0
 public DownloadQueueExternalBasicClient() :
     base(DownloadQueueExternalBasicClient.GetDefaultBinding(), DownloadQueueExternalBasicClient.GetDefaultEndpointAddress())
 {
     this.Endpoint.Name = EndpointConfiguration.BasicHttpBinding_IDownloadQueueExternalBasic.ToString();
     ConfigureEndpoint(this.Endpoint, this.ClientCredentials);
 }
 public AltinnDownloadQueueClient(Binding binding, IOptions <AltinnDownloadQueueConnectionSettings> connectionOptions)
 {
     _client            = new DownloadQueueExternalBasicClient(binding, new EndpointAddress(connectionOptions.Value.EndpointUrl));
     _connectionOptions = connectionOptions;
 }