RouteWatcher class

Inheritance

Constructors

RouteWatcher()

Properties

baseContainerOptions BaseContainerOptions
Option is parsed to a BaseContainer to determine how it is rendered
getter/setter pair
currentOptions BaseContainerOptions
no setter
currentScreen Widget
no setter
deepClean → void
Removes redundant screens when the screenViewHistory gets more than 7 active screens. acts as a flush for the screenViewHistory and the optionsHistory
no setter
eliminateCurrent int
no setter
hashCode int
The hash code for this object.
no setterinherited
hasListeners bool
Whether any listeners are currently registered.
no setterinherited
optionsHistory List<BaseContainerOptions>
A stack of the base options parsed to the the navigated screens it must always remain equal to the screenViewHistory
getter/setter pair
reset → void
no setter
routeArguments ↔ dynamic
dynamic arguments parsEed between screens. it is similar to the ModalRoute.settings feature
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
screenViewHistory List<Widget>
A stack of the navigated screens
getter/setter pair

Methods

addHead(Widget screen, {BaseContainerOptions? options = BaseContainerOptions.defaultSetup, dynamic arguments}) → void
Creates a new head node by clearing all lists and replacing it with the newly created Screens
addListener(VoidCallback listener) → void
Register a closure to be called when the object changes.
inherited
addReplacement(Widget screen, {BaseContainerOptions? options = BaseContainerOptions.defaultSetup, dynamic arguments}) → void
addTail(Widget screen, {BaseContainerOptions? options = BaseContainerOptions.defaultSetup, dynamic arguments}) → void
Creates a new tail home
addToStack(Widget screen, {BaseContainerOptions options = BaseContainerOptions.defaultSetup, dynamic arguments}) → void
Adds a new screen to the screenViewHistory stack. also accepts optional routeArguments after which it performs a deepClean on the navigation stack to keep it tidy and free of redundant screen additions
addWithFallback(Widget screen, Widget fallBackScreen, {BaseContainerOptions? options = BaseContainerOptions.defaultSetup, BaseContainerOptions? fallOptions = BaseContainerOptions.defaultSetup, dynamic arguments}) → void
creates a sequence where a fallback Screen is added to the viewHistory
addWithPurge(Widget screen, Widget purgeTail, {BaseContainerOptions? options = BaseContainerOptions.defaultSetup, dynamic arguments}) → void
Adds a new screen with a purge similar to replaceUntil It removes the screens upto a particular specified purgeTail
dispose() → void
Discards any resources used by the object. After this is called, the object is not in a usable state and should be discarded (calls to addListener will throw after the object is disposed).
inherited
emptyStack() → void
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notifyListeners() → void
Call all the registered listeners.
inherited
previousScreen() → void
access the last screen that was viewed. it pops the currentScreen and sets the preceding screen to current
removeFromStack() → void
removeListener(VoidCallback listener) → void
Remove a previously registered closure from the list of closures that are notified when the object changes.
inherited
toString() String
A string representation of this object.
override

Operators

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