AppRoute<T> constructor

AppRoute<T>({
  1. bool? allowSnapshotting,
  2. bool? barrierDismissible,
  3. bool? fullscreenDialog,
  4. bool? opaque,
  5. bool? maintainState,
  6. Color? barrierColor,
  7. String? barrierLabel,
  8. String? name,
  9. int? animationTime,
  10. int? animationReserveTime,
  11. Object? arguments,
  12. AnimationType? animationType,
  13. Curve? animationCurve,
  14. required Widget builder(
    1. BuildContext context
    ),
})

Implementation

AppRoute({
  bool? allowSnapshotting,
  bool? barrierDismissible,
  bool? fullscreenDialog,
  bool? opaque,
  bool? maintainState,
  super.barrierColor,
  super.barrierLabel,
  this.name,
  this.animationTime,
  this.animationReserveTime,
  this.arguments,
  this.animationType,
  this.animationCurve,
  required this.builder,
}) : super(
        allowSnapshotting: allowSnapshotting ?? true,
        barrierDismissible: barrierDismissible ?? false,
        fullscreenDialog: fullscreenDialog ?? false,
        opaque: opaque ?? true,
        maintainState: maintainState ?? true,
        transitionDuration: Duration(milliseconds: animationTime ?? 300),
        reverseTransitionDuration: Duration(
          milliseconds: animationReserveTime ?? animationTime ?? 300,
        ),
        pageBuilder: (_, __, ___) => builder.call(_),
        settings: RouteSettings(
          name: name,
          arguments: arguments,
        ),
      );