RouteDefinition class

A user defined route path for a router.

Route definitions are how you configure routing. Several types supported:

Constructors

RouteDefinition({String path, ComponentFactory component, bool useAsDefault, dynamic additionalData, RoutePath routePath })
Define a route from path that loads component into an outlet. [...]
factory
RouteDefinition.defer({String path, LoadComponentAsync loader, bool useAsDefault, dynamic additionalData, RoutePath routePath })
Define a route from path that uses loader to resolve a component. [...]
factory
RouteDefinition.redirect({String path, String redirectTo, bool useAsDefault, dynamic additionalData, RoutePath routePath })
Configures a redirect from a path --> to another one. [...]
factory

Properties

additionalData → dynamic
Additional information to attached to the RouteDefinition. [...]
final
parameters → Iterable<String>
Collection of parameters that are supplied in path.
read-only
path → String
Logical name used for determining a route.
final
useAsDefault → bool
Uses this Route as default if the RouterOutlet has no component.
final
hashCode → int
The hash code for this object. [...]
read-only, inherited
runtimeType → Type
A representation of the runtime type of the object.
read-only, inherited

Methods

assertValid() → void
Runs a dev-mode assertion that the definition is valid. [...]
@mustCallSuper
toRegExp() → RegExp
Returns as a regular expression that matches this route.
toUrl([Map<String, String> paramValues = const {} ]) → String
Returns as a valid URL with paramValues filled into parameters.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() → String
Returns a string representation of this object.
inherited

Operators

operator ==(dynamic other) → bool
The equality operator. [...]
inherited