HttpOptionsAttribute 类

定义

表示一个特性,该特性用于限制操作方法,使得该方法仅处理 HTTP OPTIONS 请求。

[System.AttributeUsage(System.AttributeTargets.Method, AllowMultiple=false, Inherited=true)]
public sealed class HttpOptionsAttribute : System.Web.Mvc.ActionMethodSelectorAttribute
type HttpOptionsAttribute = class
    inherit ActionMethodSelectorAttribute
Public NotInheritable Class HttpOptionsAttribute
Inherits ActionMethodSelectorAttribute
继承
属性

构造函数

HttpOptionsAttribute()

初始化 HttpOptionsAttribute 类的新实例。

方法

IsValidForRequest(ControllerContext, MethodInfo)

确定操作方法请求对指定的控制器上下文是否有效。

适用于