ConnectionBuilder Class
Definition
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.
A default implementation for IConnectionBuilder.
public ref class ConnectionBuilder : Microsoft::AspNetCore::Connections::IConnectionBuilder
public class ConnectionBuilder : Microsoft.AspNetCore.Connections.IConnectionBuilder
type ConnectionBuilder = class
interface IConnectionBuilder
Public Class ConnectionBuilder
Implements IConnectionBuilder
- Inheritance
-
ConnectionBuilder
- Implements
Constructors
ConnectionBuilder(IServiceProvider) |
Initializes a new instance of ConnectionBuilder. |
Properties
ApplicationServices |
Gets the IServiceProvider that provides access to the application's service container. |
Methods
Build() |
Builds the delegate used by this application to process connections. |
Use(Func<ConnectionDelegate,ConnectionDelegate>) |
Adds a middleware delegate to the application's connection pipeline. |
Extension Methods
Run(IConnectionBuilder, Func<ConnectionContext,Task>) |
Add the given |
Use(IConnectionBuilder, Func<ConnectionContext,ConnectionDelegate,Task>) |
Add the given |
Use(IConnectionBuilder, Func<ConnectionContext,Func<Task>,Task>) |
Add the given Prefer using Use(IConnectionBuilder, Func<ConnectionContext,ConnectionDelegate,Task>) for better performance as shown below:
|
UseConnectionHandler<TConnectionHandler>(IConnectionBuilder) |
Use the given |
UseHub<THub>(IConnectionBuilder) |
Configure the connection to host the specified Hub type. |