Table of Contents

Class ActionFilterAttribute

Namespace
System.Web.Mvc
Assembly
System.Web.Mvc.dll

Represents the base class for filter attributes.

[AttributeUsage(AttributeTargets.Class|AttributeTargets.Method, Inherited = true, AllowMultiple = false)]
public abstract class ActionFilterAttribute : FilterAttribute, IMvcFilter, IActionFilter, IResultFilter
Inheritance
ActionFilterAttribute
Implements
Derived
Inherited Members

Constructors

ActionFilterAttribute()

Initializes a new instance of the ActionFilterAttribute class.

protected ActionFilterAttribute()

Methods

OnActionExecuted(ActionExecutedContext)

Called by the ASP.NET MVC framework after the action method executes.

public virtual void OnActionExecuted(ActionExecutedContext filterContext)

Parameters

filterContext ActionExecutedContext

The filter context.

OnActionExecuting(ActionExecutingContext)

Called by the ASP.NET MVC framework before the action method executes.

public virtual void OnActionExecuting(ActionExecutingContext filterContext)

Parameters

filterContext ActionExecutingContext

The filter context.

OnResultExecuted(ResultExecutedContext)

Called by the ASP.NET MVC framework after the action result executes.

public virtual void OnResultExecuted(ResultExecutedContext filterContext)

Parameters

filterContext ResultExecutedContext

The filter context.

OnResultExecuting(ResultExecutingContext)

Called by the ASP.NET MVC framework before the action result executes.

public virtual void OnResultExecuting(ResultExecutingContext filterContext)

Parameters

filterContext ResultExecutingContext

The filter context.