HubConnectionContext Class
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Encapsulates all information about an individual connection to a SignalR Hub.
public ref class HubConnectionContext
public class HubConnectionContext
type HubConnectionContext = class
Public Class HubConnectionContext
- Inheritance
-
HubConnectionContext
Hub |
Initializes a new instance of the HubConnectionContext class. |
Hub |
Initializes a new instance of the HubConnectionContext class. |
Hub |
Initializes a new instance of the HubConnectionContext class. |
Connection |
Gets a CancellationToken that notifies when the connection is aborted. |
Connection |
Gets the ID for this connection. |
Features |
Gets the collection of features available on this connection. |
Items |
Gets a key/value collection that can be used to share data within the scope of this connection. |
Protocol |
Gets the protocol used by this connection. |
User |
Gets the user for this connection. |
User |
Gets or sets the user identifier for this connection. |
Abort() |
Aborts the connection. |
Write |
Write a HubMessage to the connection. |
Write |
This method is designed to support the framework and is not intended to be used by application code. Writes a pre-serialized message to the connection. |
Get |
Gets HttpContext from the specified connection, or |
Product | Versions |
---|---|
ASP.NET Core | 2.1, 2.2, 3.0, 3.1, 5.0, 6.0, 7.0, 8.0, 9.0 |