Partager via


ODataRoute Class

 

A route implementation for OData routes. It supports passing in a route prefix for the route as well as a path constraint that parses the request path as OData.

Namespace:   System.Web.OData.Routing
Assembly:  System.Web.OData (in System.Web.OData.dll)

Inheritance Hierarchy

System.Object
  System.Web.Http.Routing.HttpRoute
    System.Web.OData.Routing.ODataRoute

Syntax

public class ODataRoute : HttpRoute
public ref class ODataRoute : HttpRoute
type ODataRoute = 
    class
        inherit HttpRoute
    end
Public Class ODataRoute
    Inherits HttpRoute

Constructors

Name Description
System_CAPS_pubmethod ODataRoute(String, ODataPathRouteConstraint)

Initializes a new instance of the ODataRoute class.

System_CAPS_pubmethod ODataRoute(String, ODataPathRouteConstraint, HttpRouteValueDictionary, HttpRouteValueDictionary, HttpRouteValueDictionary, HttpMessageHandler)

Initializes a new instance of the ODataRoute class.

Properties

Name Description
System_CAPS_pubproperty Constraints

Gets the constraints for the route parameters.(Inherited from HttpRoute.)

System_CAPS_pubproperty DataTokens

Gets any additional data tokens not used directly to determine whether a route matches an incoming HttpRequestMessage.(Inherited from HttpRoute.)

System_CAPS_pubproperty Defaults

Gets the default values for route parameters if not provided by the incoming HttpRequestMessage.(Inherited from HttpRoute.)

System_CAPS_pubproperty Handler

Gets or sets the http route handler.(Inherited from HttpRoute.)

System_CAPS_pubproperty PathRouteConstraint

Gets the ODataPathRouteConstraint on this route.

System_CAPS_pubproperty RoutePrefix

Gets the route prefix.

System_CAPS_pubproperty RouteTemplate

Gets the route template describing the URI pattern to match against.(Inherited from HttpRoute.)

Methods

Name Description
System_CAPS_pubmethod Equals(Object)

(Inherited from Object.)

System_CAPS_protmethod Finalize()

(Inherited from Object.)

System_CAPS_pubmethod GetHashCode()

(Inherited from Object.)

System_CAPS_pubmethod GetRouteData(String, HttpRequestMessage)

Determines whether this route is a match for the incoming request by looking up the HttpRouteData for the route.(Inherited from HttpRoute.)

System_CAPS_pubmethod GetType()

(Inherited from Object.)

System_CAPS_pubmethod GetVirtualPath(HttpRequestMessage, IDictionary<String, Object>)

(Overrides HttpRoute.GetVirtualPath(HttpRequestMessage, IDictionary<String, Object>).)

System_CAPS_pubmethod HasRelaxedODataVersionConstraint()

Obsolete. Relax the version constraint. The service will allow clients to send both OData V4 and previous max version headers. Headers for the previous max version will be ignored.

System_CAPS_protmethod MemberwiseClone()

(Inherited from Object.)

System_CAPS_protmethod ProcessConstraint(HttpRequestMessage, Object, String, HttpRouteValueDictionary, HttpRouteDirection)

Determines whether this instance equals a specified route.(Inherited from HttpRoute.)

System_CAPS_pubmethod ToString()

(Inherited from Object.)

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

System.Web.OData.Routing Namespace

Return to top