ParallelRoute<T > class
Constructors
ParallelRoute ({ModularChild ? child , required String name , void popCallback (dynamic )?, bool maintainState = true , String parent = '' , String schema = '' , TransitionType ? transition , CustomTransition ? customTransition , Duration ? duration , List <ModularRoute > children = const [] , List <Middleware > middlewares = const [] , RouteContext? context , Uri ? uri , Map <ModularKey , ModularRoute > ? routeMap , Map <Type , BindContext > bindContextEntries = const {} })
ParallelRoute.child (String name , {required ModularChild child , CustomTransition ? customTransition , List <ParallelRoute > children = const [] , Duration ? duration , TransitionType ? transition , List <Middleware > middlewares = const [] })
factory
ParallelRoute.empty ()
factory
ParallelRoute.module (String name , {required Module module , List <Middleware > middlewares = const [] })
factory
Properties
bindContextEntries
→ Map <Type , BindContext >
Contains a list of all BindContexts that will need to be active when this route is active.
final inherited
child
→ ModularChild ?
Widget Builder that will be called when prompted in navigation.
final
children
→ List <ModularRoute >
Add children to this route that can be retrieved through the parent route
final inherited
context
→ RouteContext?
RouteContext belonging to the route.
final inherited
customTransition
→ CustomTransition ?
Defines a custom transition.
If the transition is TransitionType.custom, it becomes mandatory to add a CustomTransition() object.
final
duration
→ Duration ?
define the Transition duration
Default is 300 milliseconds
final
hashCode
→ int
The hash code for this object.
no setter inherited
key
↔ ModularKey
Key that references the route in the RouteContext tree.
late final inherited
maintainState
→ bool
Whether the route should remain in memory when it is inactive.
If this is true, then the route is maintained, so that any futures it is holding from the next route will properly resolve when the next route pops. If this is not necessary, this can be set to false to allow the framework to entirely discard the route's widget hierarchy when it is not visible.
If this getter would ever start returning a different value, the changedInternalState
should be invoked so that the change can take effect.
final
middlewares
→ List <Middleware >
Adds middleware that will be shared among your children.
final inherited
name
→ String
name of route
final inherited
parent
→ String
guard your parent's path
final inherited
popCallback
→ (void Function(dynamic ) ?)
final
runtimeType
→ Type
A representation of the runtime type of the object.
no setter inherited
schema
→ String
schema of route
default is ''
final inherited
transition
→ TransitionType ?
Transition performed when one page overlaps another.
default is TransitionType.defaultTransition;
final
transitions
→ Map <TransitionType , PageRouteBuilder <T > Function(Widget builder (BuildContext , ModularArguments ), Duration transitionDuration , RouteSettings settings , bool maintainState ) >
final
uri
→ Uri
Current uri of the route.
final inherited
Methods
addModule (String name , {required RouteContext module })
→ ParallelRoute <T >
Create a new Route by adding a RouteContext to the context.
copyWith ({ModularChild ? child , RouteContext? context , TransitionType ? transition , CustomTransition ? customTransition , Duration ? duration , String ? name , String ? schema , void popCallback (dynamic )?, List <Middleware > ? middlewares , List <ModularRoute > ? children , String ? parent , Uri ? uri , Map <ModularKey , ModularRoute > ? routeMap , Map <Type , BindContext > ? bindContextEntries })
→ ParallelRoute <T >
noSuchMethod (Invocation invocation )
→ dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString ()
→ String
A string representation of this object.
inherited