LengthRouteConstraint Class
Constrains a route parameter to be a string of a given length or within a given range of lengths.
Namespace: System.Web.Http.Routing.Constraints
Assembly: System.Web.Http (in System.Web.Http.dll)
Inheritance Hierarchy
System.Object
System.Web.Http.Routing.Constraints.LengthRouteConstraint
Syntax
public class LengthRouteConstraint : IHttpRouteConstraint
public ref class LengthRouteConstraint : IHttpRouteConstraint
type LengthRouteConstraint =
class
interface IHttpRouteConstraint
end
Public Class LengthRouteConstraint
Implements IHttpRouteConstraint
Constructors
Name | Description | |
---|---|---|
![]() |
LengthRouteConstraint(Int32) | |
![]() |
LengthRouteConstraint(Int32, Int32) | Initializes a new instance of the LengthRouteConstraint class that constrains a route parameter to be a string of a given length. |
Properties
Name | Description | |
---|---|---|
![]() |
Length | Gets the length of the route parameter, if one is set. |
![]() |
MaxLength | Gets the maximum length of the route parameter, if one is set. |
![]() |
MinLength | Gets the minimum length of the route parameter, if one is set. |
Methods
Name | Description | |
---|---|---|
![]() |
Equals(Object) | (Inherited from Object.) |
![]() |
Finalize() | (Inherited from Object.) |
![]() |
GetHashCode() | (Inherited from Object.) |
![]() |
GetType() | (Inherited from Object.) |
![]() |
Match(HttpRequestMessage, IHttpRoute, String, IDictionary<String, Object>, HttpRouteDirection) | |
![]() |
MemberwiseClone() | (Inherited from Object.) |
![]() |
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.Http.Routing.Constraints Namespace
Return to top