Sisk

Method

HttpServerHostContextBuilder.UseEngine

Namespace
Sisk.Core.Http.Hosting
Assembly
Sisk.Core.dll

UseEngine(HttpServerEngine) #

Sets the HTTP server engine.

C#
public HttpServerHostContextBuilder UseEngine(HttpServerEngine engine)

Parameters #

engine HttpServerEngine

The HttpServerEngine to use.

Returns #

HttpServerHostContextBuilder

The current HttpServerHostContextBuilder instance.

UseEngine<TEngine>() #

Sets the HTTP server engine using a default constructor.

C#
public HttpServerHostContextBuilder UseEngine<TEngine>() where TEngine : HttpServerEngine, new()

Returns #

HttpServerHostContextBuilder

The current HttpServerHostContextBuilder instance.

Type Parameters #

TEngine

The type of the HTTP server engine to use, which must inherit from HttpServerEngine and have a parameterless constructor.

UseEngine<TEngine>(Action<TEngine>) #

Sets the HTTP server engine using a default constructor and applies the specified configuration action.

C#
public HttpServerHostContextBuilder UseEngine<TEngine>(Action<TEngine> setup) where TEngine : HttpServerEngine, new()

Parameters #

setup Action<TEngine>

An action that configures the newly created engine instance.

Returns #

HttpServerHostContextBuilder

The current HttpServerHostContextBuilder instance.

Type Parameters #

TEngine

The type of the HTTP server engine to use, which must inherit from HttpServerEngine and have a parameterless constructor.

UseEngine<TEngine>(Func<TEngine>) #

Sets the HTTP server engine using a factory method.

C#
public HttpServerHostContextBuilder UseEngine<TEngine>(Func<TEngine> create) where TEngine : HttpServerEngine

Parameters #

create Func<TEngine>

A factory method that creates an instance of the engine.

Returns #

HttpServerHostContextBuilder

The current HttpServerHostContextBuilder instance.

Type Parameters #

TEngine

The type of the HTTP server engine to use, which must inherit from HttpServerEngine.

Type to search the documentation and the API reference.