copyWith method
Create a copy with some fields changed.
Implementation
RouteContext<T> copyWith({
BuildContext? context,
T? data,
Map<String, String>? queryParameters,
String? routeName,
String? originalRouteName,
}) {
return RouteContext<T>(
context: context ?? this.context,
data: data ?? this.data,
queryParameters: queryParameters ?? this.queryParameters,
routeName: routeName ?? this.routeName,
originalRouteName: originalRouteName ?? this.originalRouteName,
);
}