Sisk

Class

RegexRoute

Namespace
Sisk.Core.Routing
Assembly
Sisk.Core.dll

Represents an Route which it’s path is interpreted as an regular expression.

C#
public sealed class RegexRoute : Route

Inheritance #

object ← Route ← RegexRoute

Inherited Members #

Route.AnyPath, Route.Match(string, Router), Route.ToString(), Route.Get(string, Delegate?), Route.Get(string, RouteAction), Route.Post(string, Delegate?), Route.Post(string, RouteAction), Route.Put(string, Delegate?), Route.Put(string, RouteAction), Route.Patch(string, Delegate?), Route.Patch(string, RouteAction), Route.Head(string, Delegate?), Route.Head(string, RouteAction), Route.Any(string, Delegate?), Route.Any(string, RouteAction), Route.Delete(string, Delegate?), Route.Delete(string, RouteAction), Route.Options(string, Delegate?), Route.Options(string, RouteAction), Route.Query(string, Delegate?), Route.Query(string, RouteAction), Route.Bag, Route.IsAsync, Route.LogMode, Route.UseRegex, Route.UseCors, Route.Method, Route.Path, Route.Name, Route.AllowRewrites, Route.IsStatic, Route.Action, Route.RequestHandlers, Route.BypassGlobalRequestHandlers, object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

Constructors #

NameDescription
RegexRoute()Initializes a new instance of the RegexRoute class with no parameters.
RegexRoute(RouteMethod, string, RouteAction)Initializes a new instance of the RegexRoute class.
RegexRoute(RouteMethod, string, string?, RouteAction, IRequestHandler[]?)Initializes a new instance of the RegexRoute class.

Properties #

NameDescription
AllowRewritesGets whether the router can redirect requests to this route into their trailing-slash path when ForceTrailingSlash is enabled.
IsStaticGets whether this route strictly matches its Path as an route template.

Methods #

NameDescription
Match(string, Router)Tests if the specified request path matches this route path. The HTTP method is validated by the Router after the path matches.
OnPathModified(string, string)Called after the Path property is changed.

Type to search the documentation and the API reference.