DefaultRouterDelegate constructor
DefaultRouterDelegate({
- required BuildContext context,
- required void onNestedPathUpdate(),
- required String initialLocation,
- required Map<
PathGroup, List< paths,Page> Function(PathArguments)> - required PathFactory? onGeneratePath,
- required PathFactory? onUnknownPath,
- required Map<
String, Page Function(Object?)> pages, - required PageFactory? onGeneratePage,
- required PageFactory? onUnknownPage,
- required PopPageCallback? onPopPage,
- required RouteFactory? onGenerateRoute,
- required RouteFactory? onUnknownRoute,
- required TransitionDelegate transitionDelegate,
- required bool reportsRouteUpdateToEngine,
- required List<
NavigatorObserver> observers, - required String? restorationScopeId,
- required String? tag,
Implementation
DefaultRouterDelegate({
required this.context,
required this.onNestedPathUpdate,
required this.initialLocation,
required this.paths,
required this.onGeneratePath,
required this.onUnknownPath,
required this.pages,
required this.onGeneratePage,
required this.onUnknownPage,
required this.onPopPage,
required this.onGenerateRoute,
required this.onUnknownRoute,
required this.transitionDelegate,
required this.reportsRouteUpdateToEngine,
required this.observers,
required this.restorationScopeId,
required this.tag,
}) : assert(paths.isNotEmpty ||
onGeneratePath != null ||
onUnknownPath != null);