Show / Hide Table of Contents

    Class ConfigurableMiddleware<T1, T2, T3, T4, TOptions>

    Provides an base-class for configurable middleware implementation in ASP.NET Core that supports the options pattern with four dependency injected parameters.

    Inheritance
    System.Object
    MiddlewareCore
    ConfigurableMiddlewareCore<TOptions>
    ConfigurableMiddleware<T1, T2, T3, T4, TOptions>
    Implements
    IConfigurable<TOptions>
    Inherited Members
    ConfigurableMiddlewareCore<TOptions>.Options
    MiddlewareCore.Next
    Namespace: Cuemon.AspNetCore
    Assembly: Cuemon.AspNetCore.dll
    Syntax
    public abstract class ConfigurableMiddleware<T1, T2, T3, T4, TOptions> : ConfigurableMiddlewareCore<TOptions>, IConfigurable<TOptions> where TOptions : class, new()
    Type Parameters
    Name Description
    T1

    The type of the first dependency injected parameter of InvokeAsync(HttpContext, T1, T2, T3, T4).

    T2

    The type of the second dependency injected parameter of InvokeAsync(HttpContext, T1, T2, T3, T4).

    T3

    The type of the third dependency injected parameter of InvokeAsync(HttpContext, T1, T2, T3, T4).

    T4

    The type of the fourth dependency injected parameter of InvokeAsync(HttpContext, T1, T2, T3, T4).

    TOptions

    The type of the options to setup.

    Constructors

    | Improve this Doc

    ConfigurableMiddleware(RequestDelegate, IOptions<TOptions>)

    Initializes a new instance of the ConfigurableMiddleware<TOptions> class.

    Declaration
    protected ConfigurableMiddleware(RequestDelegate next, IOptions<TOptions> setup)
    Parameters
    Type Name Description
    Microsoft.AspNetCore.Http.RequestDelegate next

    The delegate of the request pipeline to invoke.

    Microsoft.Extensions.Options.IOptions<TOptions> setup

    The Microsoft.Extensions.Options.IOptions<TOptions> which need to be configured.

    | Improve this Doc

    ConfigurableMiddleware(RequestDelegate, Action<TOptions>)

    Initializes a new instance of the ConfigurableMiddleware<TOptions> class.

    Declaration
    protected ConfigurableMiddleware(RequestDelegate next, Action<TOptions> setup)
    Parameters
    Type Name Description
    Microsoft.AspNetCore.Http.RequestDelegate next

    The delegate of the request pipeline to invoke.

    System.Action<TOptions> setup

    The System.Action<T> which need to be configured.

    Methods

    | Improve this Doc

    InvokeAsync(HttpContext, T1, T2, T3, T4)

    Executes the ConfigurableMiddleware<T1, T2, T3, T4, TOptions>.

    Declaration
    public abstract Task InvokeAsync(HttpContext context, T1 di1, T2 di2, T3 di3, T4 di4)
    Parameters
    Type Name Description
    Microsoft.AspNetCore.Http.HttpContext context

    The context of the current request.

    T1 di1

    The first dependency injected parameter of InvokeAsync(HttpContext, T1, T2, T3, T4).

    T2 di2

    The second dependency injected parameter of InvokeAsync(HttpContext, T1, T2, T3, T4).

    T3 di3

    The third dependency injected parameter of InvokeAsync(HttpContext, T1, T2, T3, T4).

    T4 di4

    The fourth dependency injected parameter of InvokeAsync(HttpContext, T1, T2, T3, T4).

    Returns
    Type Description
    System.Threading.Tasks.Task

    A task that represents the execution of this middleware.

    Implements

    IConfigurable<TOptions>

    Extension Methods

    CacheableObjectResultExtensions.ToCacheableObjectResult<T>(T, DateTime, Action<TimeBasedOptions>)
    CacheableObjectResultExtensions.ToCacheableObjectResult<T>(T, Func<T, DateTime>, Action<TimeBasedOptions>)
    CacheableObjectResultExtensions.ToCacheableObjectResult<T>(T, Byte[], Action<ContentBasedOptions>)
    CacheableObjectResultExtensions.ToCacheableObjectResult<T>(T, Func<T, Byte[]>, Action<ContentBasedOptions>)
    CacheableObjectResultExtensions.ToCacheableObjectResult<T>(T, DateTime, Byte[], Action<ContentTimeBasedOptions>)
    CacheableObjectResultExtensions.ToCacheableObjectResult<T>(T, Func<T, DateTime>, Func<T, Byte[]>, Action<ContentTimeBasedOptions>)
    CacheableObjectResultExtensions.ToCacheableObjectResult<T>(T, DateTime, Func<T, Byte[]>, Action<ContentTimeBasedOptions>)
    CacheableObjectResultExtensions.ToCacheableObjectResult<T>(T, Func<T, DateTime>, Byte[], Action<ContentTimeBasedOptions>)

    See Also

    Middleware<T1, T2, T3, T4>
    • Improve this Doc
    • View Source
    Back to top Copyright 2008-2018 Weubphoria. All rights reserved.
    Generated by DocFX