Bagikan melalui


SignalRConnectionBuilderExtensions.UseHub<THub> Metode

Definisi

Konfigurasikan koneksi untuk menghosting jenis yang ditentukan Hub .

public:
generic <typename THub>
 where THub : Microsoft::AspNetCore::SignalR::Hub[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Connections::IConnectionBuilder ^ UseHub(Microsoft::AspNetCore::Connections::IConnectionBuilder ^ connectionBuilder);
public static Microsoft.AspNetCore.Connections.IConnectionBuilder UseHub<THub> (this Microsoft.AspNetCore.Connections.IConnectionBuilder connectionBuilder) where THub : Microsoft.AspNetCore.SignalR.Hub;
static member UseHub : Microsoft.AspNetCore.Connections.IConnectionBuilder -> Microsoft.AspNetCore.Connections.IConnectionBuilder (requires 'Hub :> Microsoft.AspNetCore.SignalR.Hub)
<Extension()>
Public Function UseHub(Of THub As Hub) (connectionBuilder As IConnectionBuilder) As IConnectionBuilder

Jenis parameter

THub

Jenis Hub yang akan dihosting pada koneksi.

Parameter

connectionBuilder
IConnectionBuilder

Koneksi yang akan dikonfigurasi.

Mengembalikan

Instans yang sama untuk penautan IConnectionBuilder .

Berlaku untuk