RouterListenable class

A class that contains properties related to the router.

Implemented types
Annotations

Constructors

RouterListenable()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

addListener(VoidCallback listener) → void
Adds GoRouter's listener as specified by its Listenable. GoRouteInformationProvider uses this method on creation to handle its internal ChangeNotifier. Check out the internal implementation of GoRouter and GoRouteInformationProvider to see this in action.
override
build() Future<void>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
redirector(dynamic _, GoRouterState state) String?
Checks the status result from the authStream to decide whether we need to navigate to the LandingPage or the HomePage.
removeListener(VoidCallback listener) → void
Removes GoRouter's listener as specified by its Listenable. GoRouteInformationProvider uses this method when disposing, so that it removes its callback when destroyed. Check out the internal implementation of GoRouter and GoRouteInformationProvider to see this in action.
override
toString() String
A string representation of this object.
inherited

Operators

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