MapWhenExtensions.MapWhen Method (IAppBuilder, Func<IOwinContext, Boolean>, Action<IAppBuilder>)
Branches the request pipeline based on the result of the given predicate.
Namespace: Owin
Assembly: Microsoft.Owin (in Microsoft.Owin.dll)
Syntax
public static IAppBuilder MapWhen(
this IAppBuilder app,
Func<IOwinContext, bool> predicate,
Action<IAppBuilder> configuration
)
public:
[ExtensionAttribute]
static IAppBuilder^ MapWhen(
IAppBuilder^ app,
Func<IOwinContext^, bool>^ predicate,
Action<IAppBuilder^>^ configuration
)
static member MapWhen :
app:IAppBuilder *
predicate:Func<IOwinContext, bool> *
configuration:Action<IAppBuilder> -> IAppBuilder
<ExtensionAttribute>
Public Shared Function MapWhen (
app As IAppBuilder,
predicate As Func(Of IOwinContext, Boolean),
configuration As Action(Of IAppBuilder)
) As IAppBuilder
Parameters
- app
Type: Owin.IAppBuilder
predicate
Type: System.Func<IOwinContext, Boolean>Invoked with the request environment to determine if the branch should be taken
configuration
Type: System.Action<IAppBuilder>Configures a branch to take
Return Value
Type: Owin.IAppBuilder
Returns IAppBuilder.
See Also
MapWhenExtensions Class
Owin Namespace
Return to top