Class ControllerNameRouteConstraint

Constrains the valid routes to the controllers defined in a specific module

Inheritance
System.Object
ControllerNameRouteConstraint
Implements
System.Web.Routing.IRouteConstraint
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: EPiServer.Shell.Web.Mvc
Assembly: EPiServer.Shell.dll
Version: 8.11.0
Syntax
public class ControllerNameRouteConstraint : IRouteConstraint

Constructors

ControllerNameRouteConstraint(ShellModule)

Initializes a new instance of the ControllerNameRouteConstraint class.

Declaration
public ControllerNameRouteConstraint(ShellModule module)
Parameters
Type Name Description
ShellModule module

The module searched for controllers.

Properties

ViewManager

The view manager service

Declaration
public Injected<IViewManager> ViewManager { get; set; }
Property Value
Type Description
Injected<IViewManager>

Methods

Match(HttpContextBase, Route, String, RouteValueDictionary, RouteDirection)

Determines whether the route values contains a controller parameter matching a controller in the module.

Declaration
public bool Match(HttpContextBase httpContext, Route route, string parameterName, RouteValueDictionary values, RouteDirection routeDirection)
Parameters
Type Name Description
System.Web.HttpContextBase httpContext

An object that encapsulates information about the HTTP request.

System.Web.Routing.Route route

The object that this constraint belongs to.

System.String parameterName

The name of the parameter that is being checked.

System.Web.Routing.RouteValueDictionary values

An object that contains the parameters for the URL.

System.Web.Routing.RouteDirection routeDirection

An object that indicates whether the constraint check is being performed when an incoming request is being handled or when a URL is being generated.

Returns
Type Description
System.Boolean

true if a matiching controller is found; otherwise, false.

Implements

System.Web.Routing.IRouteConstraint