| | 1 | | // Copyright (c) ZeroC, Inc. |
| | 2 | |
|
| | 3 | | using IceRpc.Transports.Tcp; |
| | 4 | | using System.Net.Security; |
| | 5 | |
|
| | 6 | | namespace IceRpc.Transports; |
| | 7 | |
|
| | 8 | | /// <summary>A class to create outgoing duplex connections.</summary> |
| | 9 | | public interface IDuplexClientTransport |
| | 10 | | { |
| | 11 | | /// <summary>Gets the default duplex client transport.</summary> |
| | 12 | | /// <value>The default duplex client transport instance is the <see cref="TcpClientTransport" />.</value> |
| 85 | 13 | | public static IDuplexClientTransport Default { get; } = new TcpClientTransport(); |
| | 14 | |
|
| | 15 | | /// <summary>Gets the transport's name.</summary> |
| | 16 | | /// <value>The transport name.</value> |
| | 17 | | string Name { get; } |
| | 18 | |
|
| | 19 | | /// <summary>Creates a new transport connection to the specified server address.</summary> |
| | 20 | | /// <param name="serverAddress">The server address of the connection.</param> |
| | 21 | | /// <param name="options">The duplex connection options.</param> |
| | 22 | | /// <param name="clientAuthenticationOptions">The SSL client authentication options.</param> |
| | 23 | | /// <returns>The new transport connection. This connection is not yet connected.</returns> |
| | 24 | | /// <remarks>The IceRPC core can call this method concurrently so it must be thread-safe.</remarks> |
| | 25 | | IDuplexConnection CreateConnection( |
| | 26 | | ServerAddress serverAddress, |
| | 27 | | DuplexConnectionOptions options, |
| | 28 | | SslClientAuthenticationOptions? clientAuthenticationOptions); |
| | 29 | | } |