예제 #1
0
 /// <summary>
 /// Maps incoming requests with the specified path to the specified <see cref="Hub"/> type.
 /// </summary>
 /// <typeparam name="THub">The <see cref="Hub"/> type to map requests to.</typeparam>
 /// <param name="endpoints">The <see cref="IEndpointBuilder"/> to add the route to.</param>
 /// <param name="pattern">The route pattern.</param>
 /// <returns>An <see cref="HubEndpointConventionBuilder"/> for endpoints associated with the connections.</returns>
 public static HubEndpointConventionBuilder MapHub <THub>(this IEndpointBuilder endpoints, string pattern) where THub : Hub =>
 endpoints.MapHub <THub>(pattern, configureOptions : null);