Microsoft.AspNetCore.Mvc.Filters Namespace

Classes

ActionExecutedContext

A context for action filters, specifically OnActionExecuted(ActionExecutedContext) calls.

ActionExecutingContext

A context for action filters, specifically OnActionExecuted(ActionExecutedContext) and OnActionExecutionAsync(ActionExecutingContext, ActionExecutionDelegate) calls.

ActionFilterAttribute

An abstract filter that asynchronously surrounds execution of the action and the action result. Subclasses should override OnActionExecuting(ActionExecutingContext), OnActionExecuted(ActionExecutedContext) or OnActionExecutionAsync(ActionExecutingContext, ActionExecutionDelegate) but not OnActionExecutionAsync(ActionExecutingContext, ActionExecutionDelegate) and either of the other two. Similarly subclasses should override OnResultExecuting(ResultExecutingContext), OnResultExecuted(ResultExecutedContext) or OnResultExecutionAsync(ResultExecutingContext, ResultExecutionDelegate) but not OnResultExecutionAsync(ResultExecutingContext, ResultExecutionDelegate) and either of the other two.

AuthorizationFilterContext

A context for authorization filters i.e. IAuthorizationFilter and IAsyncAuthorizationFilter implementations.

ExceptionContext

A context for exception filters i.e. IExceptionFilter and IAsyncExceptionFilter implementations.

ExceptionFilterAttribute

An abstract filter that runs asynchronously after an action has thrown an Exception. Subclasses must override OnException(ExceptionContext) or OnExceptionAsync(ExceptionContext) but not both.

FilterCollection
FilterContext

An abstract context for filters.

FilterDescriptor

Descriptor for an IFilterMetadata.

FilterItem

Used to associate executable filters with IFilterMetadata instances as part of FilterProviderContext. An IFilterProvider should inspect Results and set Filter and IsReusable as appropriate.

FilterProviderContext

A context for filter providers i.e. IFilterProvider implementations.

FilterScope

Contains constant values for known filter scopes.

Scope defines the ordering of filters that have the same order. Scope is by-default defined by how a filter is registered.

PageHandlerExecutedContext

A context for page filters, used specifically in OnPageHandlerExecuted(PageHandlerExecutedContext) and OnPageHandlerExecutionAsync(PageHandlerExecutingContext, PageHandlerExecutionDelegate).

PageHandlerExecutingContext

A context for page filters, used specifically in OnPageHandlerExecuting(PageHandlerExecutingContext) and OnPageHandlerExecutionAsync(PageHandlerExecutingContext, PageHandlerExecutionDelegate).

PageHandlerSelectedContext

A context for page filters, used specifically in OnPageHandlerSelected(PageHandlerSelectedContext) and OnPageHandlerSelectionAsync(PageHandlerSelectedContext).

ResourceExecutedContext

A context for resource filters, specifically OnResourceExecuted(ResourceExecutedContext) calls.

ResourceExecutingContext

A context for resource filters, specifically OnResourceExecuting(ResourceExecutingContext) and OnResourceExecutionAsync(ResourceExecutingContext, ResourceExecutionDelegate) calls.

ResultExecutedContext

A context for result filters, specifically OnResultExecuted(ResultExecutedContext) calls.

ResultExecutingContext

A context for result filters, specifically OnResultExecuting(ResultExecutingContext) and OnResultExecutionAsync(ResultExecutingContext, ResultExecutionDelegate) calls.

ResultFilterAttribute

An abstract filter that asynchronously surrounds execution of the action result. Subclasses must override OnResultExecuting(ResultExecutingContext), OnResultExecuted(ResultExecutedContext) or OnResultExecutionAsync(ResultExecutingContext, ResultExecutionDelegate) but not OnResultExecutionAsync(ResultExecutingContext, ResultExecutionDelegate) and either of the other two.

Interfaces

IActionFilter

A filter that surrounds execution of the action.

IAlwaysRunResultFilter

A filter that surrounds execution of all action results.

IAsyncActionFilter

A filter that asynchronously surrounds execution of the action, after model binding is complete.

IAsyncAlwaysRunResultFilter

A filter that asynchronously surrounds execution of all action results.

IAsyncAuthorizationFilter

A filter that asynchronously confirms request authorization.

IAsyncExceptionFilter

A filter that runs asynchronously after an action has thrown an Exception.

IAsyncPageFilter

A filter that asynchronously surrounds execution of a page handler method. This filter is executed only when decorated on a handler's type and not on individual handler methods.

IAsyncResourceFilter

A filter that asynchronously surrounds execution of model binding, the action (and filters) and the action result (and filters).

IAsyncResultFilter

A filter that asynchronously surrounds execution of action results successfully returned from an action.

IAuthorizationFilter

A filter that confirms request authorization.

IExceptionFilter

A filter that runs after an action has thrown an Exception.

IFilterContainer

A filter that requires a reference back to the IFilterFactory that created it.

IFilterFactory

An interface for filter metadata which can create an instance of an executable filter.

IFilterMetadata

Marker interface for filters handled in the MVC request pipeline.

IFilterProvider

A FilterItem provider. Implementations should update Results to make executable filters available.

IOrderedFilter

A filter that specifies the relative order it should run.

IPageFilter

A filter that surrounds execution of a page handler method. This filter is executed only when decorated on a handler's type and not on individual handler methods.

IResourceFilter

A filter that surrounds execution of model binding, the action (and filters) and the action result (and filters).

IResultFilter

A filter that surrounds execution of action results successfully returned from an action.

Delegates

ActionExecutionDelegate

A delegate that asynchronously returns an ActionExecutedContext indicating the action or the next action filter has executed.

PageHandlerExecutionDelegate

A delegate that asynchronously returns a PageHandlerExecutedContext indicating the page or the next page filter has executed.

ResourceExecutionDelegate

A delegate that asynchronously returns a ResourceExecutedContext indicating model binding, the action, the action's result, result filters, and exception filters have executed.

ResultExecutionDelegate

A delegate that asynchronously returns an ResultExecutedContext indicating the action result or the next result filter has executed.