Route class

Implemented types

Constructors

Route.delete(String name, Function handler, {List<ModularMiddleware> middlewares = const []})
factory
Route.get(String name, Function handler, {List<ModularMiddleware> middlewares = const []})
factory
Route.module(String name, {required Module module, List<ModularMiddleware> middlewares = const []})
factory
Route.path(String name, Function handler, {List<ModularMiddleware> middlewares = const []})
factory
Route.post(String name, Function handler, {List<ModularMiddleware> middlewares = const []})
factory
Route.put(String name, Function handler, {List<ModularMiddleware> middlewares = const []})
factory
Route.resource(Resource resource, {List<ModularMiddleware> middlewares = const []})
factory
Route.websocket(String name, {required WebSocketResource websocket, List<ModularMiddleware> middlewares = const []})
factory

Properties

bindContextEntries Map<Type, BindContext>
finalinherited
children List<ModularRoute>
finalinherited
context → RouteContext?
finalinherited
handler Function?
final
hashCode int
The hash code for this object.
no setterinherited
key ↔ ModularKey
latefinalinherited
middlewares List<Middleware>
finalinherited
name String
finalinherited
parent String
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
schema String
finalinherited
uri Uri
finalinherited

Methods

addModule(String name, {required RouteContext module}) ModularRoute
Create a new Route by adding a RouteContext to the context.
inherited
copyWith({Handler? handler, String? name, String? schema, RouteContext? context, List<Middleware>? middlewares, List<ModularRoute>? children, String? parent, Uri? uri, Map<ModularKey, ModularRoute>? routeMap, Map<Type, BindContext>? bindContextEntries}) Route
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited