AppBuilderUseExtensions.Use Method

 

Namespace:   Owin
Assembly:  Microsoft.Owin (in Microsoft.Owin.dll)

Overload List

Name Description
System_CAPS_pubmethodSystem_CAPS_static Use(IAppBuilder, Func<IOwinContext, Func<Task>, Task>)

Inserts a middleware into the OWIN pipeline.

System_CAPS_pubmethodSystem_CAPS_static Use<T>(IAppBuilder, Object[])

Inserts a middleware into the OWIN pipeline.

See Also

AppBuilderUseExtensions Class
Owin Namespace

Return to top

AppBuilderUseExtensions.Use Method (IAppBuilder, Func<IOwinContext, Func<Task>, Task>)

Inserts a middleware into the OWIN pipeline.

Syntax

public static IAppBuilder Use(
    this IAppBuilder app,
    Func<IOwinContext, Func<Task>, Task> handler
)
public:
[ExtensionAttribute]
static IAppBuilder^ Use(
    IAppBuilder^ app,
    Func<IOwinContext^, Func<Task^>^, Task^>^ handler
)
static member Use : 
        app:IAppBuilder *
        handler:Func<IOwinContext, Func<Task>, Task> -> IAppBuilder
<ExtensionAttribute>
Public Shared Function Use (
    app As IAppBuilder,
    handler As Func(Of IOwinContext, Func(Of Task), Task)
) As IAppBuilder

Parameters

  • app
    Type: Owin.IAppBuilder

Return Value

Type: Owin.IAppBuilder

Returns IAppBuilder.

Return to top

AppBuilderUseExtensions.Use<T> Method (IAppBuilder, Object[])

Inserts a middleware into the OWIN pipeline.

Syntax

public static IAppBuilder Use<T>(
    this IAppBuilder app,
    params object[] args
)
public:
generic<typename T>
[ExtensionAttribute]
static IAppBuilder^ Use(
    IAppBuilder^ app,
    ... array<Object^>^ args
)
static member Use<'T> : 
        app:IAppBuilder *
        [<ParamArrayAttribute>] args:Object[] -> IAppBuilder
<ExtensionAttribute>
Public Shared Function Use(Of T) (
    app As IAppBuilder,
    ParamArray args As Object()
) As IAppBuilder

Parameters

  • app
    Type: Owin.IAppBuilder
  • args
    Type: System.Object[]

    Any additional arguments for the middleware constructor

Return Value

Type: Owin.IAppBuilder

Returns IAppBuilder.

Type Parameters

  • T
    The middleware type

Return to top