GeneratedRouterDelegate<T extends Object> class final

Navigator 2.0 delegate used by generated routers.

Inheritance
Mixed-in types

Constructors

GeneratedRouterDelegate(RouterRuntimeConfig<T> config)
Creates a router delegate from generated config.

Properties

config RouterRuntimeConfig<T>
Generated router runtime configuration.
final
currentConfiguration → T
Called by the Router when it detects a route information may have changed as a result of rebuild.
no setteroverride
currentRoute → T
Last route in the stack, or the configured initial route.
no setter
debugPageKeys List<LocalKey>
Stack entry keys exposed for router runtime tests.
no setter
hashCode int
The hash code for this object.
no setterinherited
hasListeners bool
Whether any listeners are currently registered.
no setterinherited
The key used for retrieving the current navigator.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
stack RouteStack<T>
Mutable route stack used by Navigator.pages.
no setter

Methods

addListener(VoidCallback listener) → void
Register a closure to be called when the object changes.
inherited
build(BuildContext context) Widget
Called by the Router to obtain the widget tree that represents the current state.
override
debugWaitForScheduledRefresh() Future<void>
Waits for the latest route refresh scheduled by RouterBase.refreshListenable.
dispose() → void
Discards any resources used by the object.
override
go(T route) → void
Navigates to route, replacing the current stack.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notifyListeners() → void
Call all the registered listeners.
inherited
pop<R>([R? result]) bool
Pops the top route and completes its push future with result.
popRoute() Future<bool>
Called by the Router when the Router.backButtonDispatcher reports that the operating system is requesting that the current route be popped.
override
push<R>(T route) Future<R?>
Pushes route on top of the current stack.
removeListener(VoidCallback listener) → void
Remove a previously registered closure from the list of closures that are notified when the object changes.
inherited
replace(T route) → void
Replaces the current top route with route.
setInitialRoutePath(T configuration) Future<void>
Called by the Router at startup with the structure that the RouteInformationParser obtained from parsing the initial route.
inherited
setNewRoutePath(T configuration) Future<void>
Called by the Router when the Router.routeInformationProvider reports that a new route has been pushed to the application by the operating system.
override
setRestoredRoutePath(T configuration) Future<void>
Called by the Router during state restoration.
inherited
toString() String
A string representation of this object.
inherited

Operators

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