Partager via


FilterAttributeFilterProvider.GetControllerAttributes Method

Gets a collection of controller attributes.

Namespace:  System.Web.Mvc
Assembly:  System.Web.Mvc (in System.Web.Mvc.dll)

Syntax

'Declaration
Protected Overridable Function GetControllerAttributes ( _
    controllerContext As ControllerContext, _
    actionDescriptor As ActionDescriptor _
) As IEnumerable(Of FilterAttribute)
'Usage
Dim controllerContext As ControllerContext
Dim actionDescriptor As ActionDescriptor
Dim returnValue As IEnumerable(Of FilterAttribute)

returnValue = Me.GetControllerAttributes(controllerContext, _
    actionDescriptor)
protected virtual IEnumerable<FilterAttribute> GetControllerAttributes(
    ControllerContext controllerContext,
    ActionDescriptor actionDescriptor
)
protected:
virtual IEnumerable<FilterAttribute^>^ GetControllerAttributes(
    ControllerContext^ controllerContext, 
    ActionDescriptor^ actionDescriptor
)
protected function GetControllerAttributes(
    controllerContext : ControllerContext, 
    actionDescriptor : ActionDescriptor
) : IEnumerable<FilterAttribute>

Parameters

Return Value

Type: System.Collections.Generic.IEnumerable<FilterAttribute>
A collection of controller attributes.

See Also

Reference

FilterAttributeFilterProvider Class

System.Web.Mvc Namespace