コード例 #1
0
 internal static ConnectionClient Get(EndPoint endPoint, bool withRetries, int retryLimit, int httpClientTimeoutMilliseconds) => Clients.GetOrAdd(endPoint, (e) =>
 {
     var connectionClient = new ConnectionClient(endPoint, withRetries, retryLimit, httpClientTimeoutMilliseconds);
     Events.RaiseClientCreated(connectionClient);
     return(connectionClient);
 });
コード例 #2
0
 public static void Remove(ConnectionClient connectionClient)
 {
     Events.RaiseClientDisposed(connectionClient);
     Clients.TryRemove(connectionClient.EndPoint, out var c);
 }