Udostępnij za pośrednictwem


HubPipelineModule.BuildDisconnect Method

.NET Framework 4

Wraps a function that is called when a client disconnects from the HubDispatcher for each IHub the client was connected to. By default, this results in the IHub 's OnDisconnected method being invoked.

Namespace:  Microsoft.AspNet.SignalR.Hubs
Assembly:  Microsoft.AspNet.SignalR.Core (in Microsoft.AspNet.SignalR.Core.dll)

Syntax

'Declaration
Public Overridable Function BuildDisconnect ( _
    disconnect As Func(Of IHub, Task) _
) As Func(Of IHub, Task)
'Usage
Dim instance As HubPipelineModule 
Dim disconnect As Func(Of IHub, Task)
Dim returnValue As Func(Of IHub, Task)

returnValue = instance.BuildDisconnect(disconnect)
public virtual Func<IHub, Task> BuildDisconnect(
    Func<IHub, Task> disconnect
)
public:
virtual Func<IHub^, Task^>^ BuildDisconnect(
    Func<IHub^, Task^>^ disconnect
)
abstract BuildDisconnect : 
        disconnect:Func<IHub, Task> -> Func<IHub, Task> 
override BuildDisconnect : 
        disconnect:Func<IHub, Task> -> Func<IHub, Task> 
public function BuildDisconnect(
    disconnect : Func<IHub, Task>
) : Func<IHub, Task>

Parameters

  • disconnect
    Type: System.Func<IHub, Task>
    A function to be called when a client disconnects from a hub.

Return Value

Type: System.Func<IHub, Task>
A wrapped function to be called when a client disconnects from a hub.

Implements

IHubPipelineModule.BuildDisconnect(Func<IHub, Task>)

See Also

Reference

HubPipelineModule Class

Microsoft.AspNet.SignalR.Hubs Namespace