Share via


ODataAttributeRoutingAttribute Class

Definition

When used to decorate a Controller or Controller method, automatically opts that item into OData routing conventions.

[System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method, AllowMultiple=false)]
public sealed class ODataAttributeRoutingAttribute : Attribute
[<System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method, AllowMultiple=false)>]
type ODataAttributeRoutingAttribute = class
    inherit Attribute
Public NotInheritable Class ODataAttributeRoutingAttribute
Inherits Attribute
Inheritance
ODataAttributeRoutingAttribute
Attributes

Remarks

NOTE: If your Controller inherits from ODataController, this attribute is NOT required.

To allow individual methods to opt out of the OData routing conventions, add the [ODataIgnored] attribute to that method.

Constructors

ODataAttributeRoutingAttribute()

Applies to