43 types derived from Hub
JwtSample (1)
Broadcaster.cs (1)
11public class Broadcaster : Hub
Microsoft.AspNetCore.Components.Server (1)
ComponentHub.cs (1)
36internal sealed partial class ComponentHub : Hub
Microsoft.AspNetCore.SignalR.Client.FunctionalTests (4)
Hubs.cs (4)
17public class TestHub : Hub 306public class VersionHub : Hub 317public class HubWithAuthorization : Hub 323public class HubWithAuthorization2 : Hub
Microsoft.AspNetCore.SignalR.Client.Tests (1)
TestServerTests.cs (1)
114class EchoHub : Hub
Microsoft.AspNetCore.SignalR.Core (2)
DynamicHub.cs (1)
12public abstract class DynamicHub : Hub
Hub`T.cs (1)
14public abstract class Hub<[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.All)] T> : Hub where T : class
Microsoft.AspNetCore.SignalR.Microbenchmarks (3)
DefaultHubActivatorBenchmark.cs (1)
30public class MyHub : Hub
DefaultHubDispatcherBenchmark.cs (1)
108public class TestHub : Hub
RedisHubLifetimeManagerBenchmark.cs (1)
165public class TestHub : Hub
Microsoft.AspNetCore.SignalR.StackExchangeRedis.Tests (1)
EchoHub.cs (1)
9public class EchoHub : Hub
Microsoft.AspNetCore.SignalR.Tests (23)
AddSignalRTests.cs (1)
200public class CustomHub : Hub
AuthHub.cs (1)
9class AuthHub : Hub
ClientProxyTests.cs (1)
17public class FakeHub : Hub
DefaultHubActivatorTests.cs (1)
14public class CreatableHub : Hub
HubConnectionHandlerTestUtils\Hubs.cs (14)
396public abstract class TestHub : Hub 589public class OnConnectedThrowsHub : Hub 652public class GenericMethodHub : Hub 692public class AbortHub : Hub 981public class SimpleHub : Hub 1009public class LongRunningHub : Hub 1236public class ErrorInAbortedTokenHub : Hub 1258public class ConnectionLifetimeHub : Hub 1309public class OnConnectedClientResultHub : Hub 1317public class OnDisconnectedClientResultHub : Hub 1325public class CallerServiceHub : Hub 1439public class BadServicesHub : Hub 1446public class TooManyParamsHub : Hub 1457public class OnConnectedSendToClientHub : Hub
HubReflectionHelperTests.cs (2)
45private class EmptyHub : Hub 49private class BaseMethodHub : Hub
MapSignalRTests.cs (2)
366private class InvalidHub : Hub 387private class AuthHub : Hub
UncreatableHub.cs (1)
6public class UncreatableHub : Hub
SignalR.Client.FunctionalTestApp (3)
AuthorizedHub.cs (1)
11public class HubWithAuthorization : Hub
TestHub.cs (1)
21public class TestHub : Hub
UncreatableHub.cs (1)
8public class UncreatableHub : Hub
SignalRSamples (3)
Hubs\Chat.cs (1)
8public class Chat : Hub
Hubs\Streaming.cs (1)
10public class Streaming : Hub
Hubs\UploadHub.cs (1)
11public class UploadHub : Hub
SignalRWeb (1)
Hubs\ChatHub.cs (1)
3public class ChatHub : Hub
113 references to Hub
Microsoft.AspNetCore.Components.Server (7)
Builder\ComponentEndpointRouteBuilderExtensions.cs (6)
17/// Maps the Blazor <see cref="Hub" /> to the default path. 29/// Maps the Blazor <see cref="Hub" /> to the path <paramref name="path"/>. 32/// <param name="path">The path to map the Blazor <see cref="Hub" />.</param> 45///Maps the Blazor <see cref="Hub" /> to the default path. 61/// Maps the Blazor <see cref="Hub" /> to the path <paramref name="path"/>. 64/// <param name="path">The path to map the Blazor <see cref="Hub" />.</param>
Builder\ServerRazorComponentsEndpointConventionBuilderExtensions.cs (1)
28/// Maps the Blazor <see cref="Hub" /> to the default path.
Microsoft.AspNetCore.SignalR (8)
HubEndpointRouteBuilderExtensions.cs (7)
13/// Extension methods on <see cref="IEndpointRouteBuilder"/> to add routes to <see cref="Hub"/>s. 20/// Maps incoming requests with the specified path to the specified <see cref="Hub"/> type. 22/// <typeparam name="THub">The <see cref="Hub"/> type to map requests to.</typeparam> 26public static HubEndpointConventionBuilder MapHub<[DynamicallyAccessedMembers(HubAccessibility)] THub>(this IEndpointRouteBuilder endpoints, [StringSyntax("Route")] string pattern) where THub : Hub 32/// Maps incoming requests with the specified path to the specified <see cref="Hub"/> type. 34/// <typeparam name="THub">The <see cref="Hub"/> type to map requests to.</typeparam> 39public static HubEndpointConventionBuilder MapHub<[DynamicallyAccessedMembers(HubAccessibility)] THub>(this IEndpointRouteBuilder endpoints, [StringSyntax("Route")] string pattern, Action<HttpConnectionDispatcherOptions>? configureOptions) where THub : Hub
SignalRDependencyInjectionExtensions.cs (1)
23public static ISignalRServerBuilder AddHubOptions<THub>(this ISignalRServerBuilder signalrBuilder, Action<HubOptions<THub>> configure) where THub : Hub
Microsoft.AspNetCore.SignalR.Core (56)
DefaultHubLifetimeManager.cs (2)
14/// A default in-memory lifetime manager abstraction for <see cref="Hub"/> instances. 16public class DefaultHubLifetimeManager<THub> : HubLifetimeManager<THub> where THub : Hub
Hub.cs (1)
90/// Releases all resources currently used by this <see cref="Hub"/> instance.
HubConnectionHandler.cs (2)
20public class HubConnectionHandler<[DynamicallyAccessedMembers(Hub.DynamicallyAccessedMembers)] THub> : ConnectionHandler where THub : Hub
HubInvocationContext.cs (3)
24public HubInvocationContext(HubCallerContext context, IServiceProvider serviceProvider, Hub hub, MethodInfo hubMethod, IReadOnlyList<object?> hubMethodArguments) 33internal HubInvocationContext(ObjectMethodExecutor objectMethodExecutor, HubCallerContext context, IServiceProvider serviceProvider, Hub hub, object?[] hubMethodArguments) 47public Hub Hub { get; }
HubLifetimeContext.cs (4)
7/// Context for the hub lifetime events <see cref="Hub.OnConnectedAsync"/> and <see cref="Hub.OnDisconnectedAsync(Exception)"/>. 17public HubLifetimeContext(HubCallerContext context, IServiceProvider serviceProvider, Hub hub) 32public Hub Hub { get; }
HubLifetimeManager.cs (2)
10/// A lifetime manager abstraction for <see cref="Hub"/> instances. 12public abstract class HubLifetimeManager<THub> where THub : Hub
HubMetadata.cs (4)
7/// Metadata that describes the <see cref="Hub"/> information associated with a specific endpoint. 12/// Constructs the <see cref="HubMetadata"/> of the given <see cref="Hub"/> type. 14/// <param name="hubType">The <see cref="Type"/> of the <see cref="Hub"/>.</param> 21/// The type of <see cref="Hub"/>.
HubOptions`T.cs (1)
10public class HubOptions<THub> : HubOptions where THub : Hub
HubOptionsSetup`T.cs (2)
11/// <typeparam name="THub">The <see cref="Hub"/> type to configure.</typeparam> 12public class HubOptionsSetup<THub> : IConfigureOptions<HubOptions<THub>> where THub : Hub
IHubActivator.cs (3)
9/// A <see cref="Hub"/> activator abstraction. 12public interface IHubActivator<[DynamicallyAccessedMembers(Hub.DynamicallyAccessedMembers)] THub> where THub : Hub
IHubContext.cs (1)
25public interface IHubContext<out THub> where THub : Hub
IHubFilter.cs (2)
20/// Allows handling of the <see cref="Hub.OnConnectedAsync"/> method. 28/// Allows handling of the <see cref="Hub.OnDisconnectedAsync(Exception)"/> method.
Internal\DefaultHubActivator.cs (2)
10internal sealed class DefaultHubActivator<[DynamicallyAccessedMembers(Hub.DynamicallyAccessedMembers)] THub> : IHubActivator<THub> where THub : Hub
Internal\DefaultHubDispatcher.cs (5)
21internal sealed partial class DefaultHubDispatcher<[DynamicallyAccessedMembers(Hub.DynamicallyAccessedMembers)] THub> : HubDispatcher<THub> where THub : Hub 618private ValueTask<object?> ExecuteMethod(string hubMethodName, Hub hub, object?[] arguments) 628private static async ValueTask<object?> ExecuteMethod(ObjectMethodExecutor methodExecutor, Hub hub, object?[] arguments) 665private static Task<bool> IsHubMethodAuthorized(IServiceProvider provider, HubConnectionContext hubConnectionContext, HubMethodDescriptor descriptor, object?[] hubMethodArguments, Hub hub)
Internal\GroupManager.cs (1)
6internal sealed class GroupManager<THub> : IGroupManager where THub : Hub
Internal\HubClients.cs (1)
6internal sealed class HubClients<THub> : IHubClients where THub : Hub
Internal\HubClients`T.cs (1)
9internal sealed class HubClients<THub, [DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.All)] T> : IHubClients<T> where THub : Hub
Internal\HubConnectionBinder.cs (2)
8internal sealed class HubConnectionBinder<[DynamicallyAccessedMembers(Hub.DynamicallyAccessedMembers)] THub> : IInvocationBinder where THub : Hub
Internal\HubContext.cs (1)
6internal sealed class HubContext<THub> : IHubContext, IHubContext<THub> where THub : Hub
Internal\HubDispatcher.cs (2)
9internal abstract class HubDispatcher<[DynamicallyAccessedMembers(Hub.DynamicallyAccessedMembers)] THub> where THub : Hub
Internal\HubReflectionHelper.cs (1)
29return typeof(Hub) != baseType;
Internal\Proxies.cs (9)
6internal sealed class UserProxy<THub> : IClientProxy where THub : Hub 25internal sealed class MultipleUserProxy<THub> : IClientProxy where THub : Hub 42internal sealed class GroupProxy<THub> : IClientProxy where THub : Hub 61internal sealed class MultipleGroupProxy<THub> : IClientProxy where THub : Hub 78internal sealed class GroupExceptProxy<THub> : IClientProxy where THub : Hub 99internal sealed class AllClientProxy<THub> : IClientProxy where THub : Hub 114internal sealed class AllClientsExceptProxy<THub> : IClientProxy where THub : Hub 131internal sealed class MultipleClientProxy<THub> : IClientProxy where THub : Hub 148internal sealed class SingleClientProxy<THub> : ISingleClientProxy where THub : Hub
SignalRConnectionBuilderExtensions.cs (4)
16/// Configure the connection to host the specified <see cref="Hub"/> type. 18/// <typeparam name="THub">The <see cref="Hub"/> type to host on the connection.</typeparam> 21public static IConnectionBuilder UseHub<[DynamicallyAccessedMembers(Hub.DynamicallyAccessedMembers)] THub>(this IConnectionBuilder connectionBuilder) where THub : Hub
Microsoft.AspNetCore.SignalR.Microbenchmarks (8)
BroadcastBenchmark.cs (5)
16private DefaultHubLifetimeManager<Hub> _hubLifetimeManager; 17private HubContext<Hub> _hubContext; 28_hubLifetimeManager = new DefaultHubLifetimeManager<Hub>(NullLogger<DefaultHubLifetimeManager<Hub>>.Instance); 58_hubContext = new HubContext<Hub>(_hubLifetimeManager);
DefaultHubLifetimeManagerBenchmark.cs (3)
13private DefaultHubLifetimeManager<Hub> _hubLifetimeManager; 25_hubLifetimeManager = new DefaultHubLifetimeManager<Hub>(NullLogger<DefaultHubLifetimeManager<Hub>>.Instance);
Microsoft.AspNetCore.SignalR.Specification.Tests (4)
HubLifetimeManagerTestBase.cs (2)
14/// <typeparam name="THub">The type of the <see cref="Hub"/>.</typeparam> 15public abstract class HubLifetimeManagerTestsBase<THub> where THub : Hub
ScaleoutHubLifetimeManagerTests.cs (2)
15public abstract class ScaleoutHubLifetimeManagerTests<TBackplane> : HubLifetimeManagerTestsBase<Hub> 28public abstract HubLifetimeManager<Hub> CreateNewHubLifetimeManager(TBackplane backplane);
Microsoft.AspNetCore.SignalR.StackExchangeRedis (2)
RedisHubLifetimeManager.cs (2)
23/// <typeparam name="THub">The type of <see cref="Hub"/> to manage connections for.</typeparam> 24public class RedisHubLifetimeManager<THub> : HubLifetimeManager<THub>, IDisposable where THub : Hub
Microsoft.AspNetCore.SignalR.StackExchangeRedis.Tests (7)
RedisHubLifetimeManagerTests.cs (7)
30private RedisHubLifetimeManager<Hub> CreateLifetimeManager(TestRedisServer server, MessagePackHubProtocolOptions messagePackOptions = null, NewtonsoftJsonHubProtocolOptions jsonOptions = null) 35return new RedisHubLifetimeManager<Hub>( 36NullLogger<RedisHubLifetimeManager<Hub>>.Instance, 100var loggerT = mockLoggerFactory.Object.CreateLogger<RedisHubLifetimeManager<Hub>>(); 102var manager = new RedisHubLifetimeManager<Hub>( 153public override HubLifetimeManager<Hub> CreateNewHubLifetimeManager() 159public override HubLifetimeManager<Hub> CreateNewHubLifetimeManager(TestRedisServer backplane)
Microsoft.AspNetCore.SignalR.Tests (21)
AddSignalRTests.cs (3)
230public class CustomHubActivator<THub> : IHubActivator<THub> where THub : Hub 243public class CustomHubContext<THub> : IHubContext<THub> where THub : Hub 259public class CustomHubLifetimeManager<THub> : HubLifetimeManager<THub> where THub : Hub
ClientProxyTests.cs (1)
220internal class EmptyHubLifetimeManager<THub> : HubLifetimeManager<THub> where THub : Hub
DefaultHubActivatorTests.cs (8)
28var hub = Mock.Of<Hub>(); 31.Setup(sp => sp.GetService(typeof(Hub))) 35new DefaultHubActivator<Hub>(mockServiceProvider.Object).Create()); 43.Setup(sp => sp.GetService(typeof(Hub))) 46var m = new Mock<Hub>(); 51var hubActivator = new DefaultHubActivator<Hub>(mockServiceProvider.Object); 62() => new DefaultHubActivator<Hub>(Mock.Of<IServiceProvider>()).Release(null)).ParamName);
DefaultHubLifetimeManagerTests.cs (4)
16public class DefaultHubLifetimeManagerTests : HubLifetimeManagerTestsBase<Hub> 18public override HubLifetimeManager<Hub> CreateNewHubLifetimeManager() 20return new DefaultHubLifetimeManager<Hub>(new Logger<DefaultHubLifetimeManager<Hub>>(NullLoggerFactory.Instance));
HubConnectionHandlerTests.cs (5)
692var mockLifetimeManager = new Mock<HubLifetimeManager<Hub>>(); 696var mockHubActivator = new Mock<IHubActivator<Hub>>(); 704var connectionHandler = serviceProvider.GetService<HubConnectionHandler<Hub>>(); 723mockHubActivator.Verify(m => m.Release(It.IsAny<Hub>()), Times.Never); 5361private class CustomHubActivator<THub> : IHubActivator<THub> where THub : Hub