共用方式為


IMvcFilter.AllowMultiple Property

 

When implemented in a class, gets or sets a value that indicates whether multiple filters are allowed.

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

Syntax

bool AllowMultiple { get; }
property bool AllowMultiple {
    bool get();
}
abstract AllowMultiple : bool with get
ReadOnly Property AllowMultiple As Boolean

Property Value

Type: System.Boolean

true if multiple filters are allowed; otherwise, false.

Remarks

This property is used during sorting in order to eliminate duplicate filters. When AllowMultiple is true, all instances of the same filter type are allowed. When AllowMultiple is false, only the last instance of the same filter type is allowed, and all others are discarded. If your filter does not implement IMvcFilter, the default value for AllowMultiple is true.

See Also

IMvcFilter Interface
System.Web.Mvc Namespace

Return to top