Class ModuleRouteCollection

A route that composed of sub-routes. The route will defer work to the contained routes when the url matches a base path defiend for the route chainer.

Inheritance
System.Object
ModuleRouteCollection
Implements
System.Collections.Generic.IEnumerable<System.Web.Routing.RouteBase>
System.Collections.IEnumerable
Namespace: EPiServer.Shell.Web.Routing
Assembly: EPiServer.Shell.dll
Version: 8.11.0
Syntax
public class ModuleRouteCollection : RouteBase, IEnumerable<RouteBase>, IEnumerable

Constructors

ModuleRouteCollection(String)

Creates the ModuleRouteCollection instance

Declaration
public ModuleRouteCollection(string routePath)
Parameters
Type Name Description
System.String routePath

The top-level path this route is restricted to

Properties

RoutePath

The base path that constrains routes within this collection. Other paths will be ignored without processing.

Declaration
public string RoutePath { get; }
Property Value
Type Description
System.String

Methods

Add(String, RouteBase)

Adds a route and associates it with the module.

Declaration
public RouteBase Add(string moduleName, RouteBase route)
Parameters
Type Name Description
System.String moduleName

The module name.

System.Web.Routing.RouteBase route

The route base.

Returns
Type Description
System.Web.Routing.RouteBase

GetEnumerator()

Returns an enumerator that iterates through the routes.

Declaration
public IEnumerator<RouteBase> GetEnumerator()
Returns
Type Description
System.Collections.Generic.IEnumerator<System.Web.Routing.RouteBase>

A System.Collections.Generic.IEnumerator<T> that can be used to iterate through the collection.

GetRouteData(HttpContextBase)

Gets route data from contained routes

Declaration
public override RouteData GetRouteData(HttpContextBase httpContext)
Parameters
Type Name Description
System.Web.HttpContextBase httpContext

The http context

Returns
Type Description
System.Web.Routing.RouteData

A route or null if non was found

GetVirtualPath(RequestContext, RouteValueDictionary)

Gets the virtual path for routes within this collection

Declaration
public override VirtualPathData GetVirtualPath(RequestContext requestContext, RouteValueDictionary values)
Parameters
Type Name Description
System.Web.Routing.RequestContext requestContext
System.Web.Routing.RouteValueDictionary values
Returns
Type Description
System.Web.Routing.VirtualPathData

A path data or null if no matching route

ToString()

Returns a System.String that represents this instance.

Declaration
public override string ToString()
Returns
Type Description
System.String

A System.String that represents this instance.

Explicit Interface Implementations

IEnumerable.GetEnumerator()

Declaration
IEnumerator IEnumerable.GetEnumerator()
Returns
Type Description
System.Collections.IEnumerator

Implements

System.Collections.Generic.IEnumerable<T>
System.Collections.IEnumerable