copyWith method
AppState
copyWith({
- AppAuthStatus? appAuthStatus,
- AppStatus? appStatus,
- double? progress,
- String? progressHeaderText,
- String? currentPath,
- int? colorThemeIndex,
- ValueGetter<
List< ? overlayFullScreenChild,Widget Function()> > - int? overlayFullScreenChildCount,
- NetworkStatus? networkStatus,
- String? networkErrorMessage,
- bool? showNetworkRetry,
- VersionUpdateInfo? versionUpdateInfo,
- bool? showVersionUpdateBanner,
- int? unreadNotificationCount,
- NotificationPermissionStatus? notificationPermissionStatus,
Implementation
AppState copyWith({
AppAuthStatus? appAuthStatus,
AppStatus? appStatus,
double? progress,
String? progressHeaderText,
String? currentPath,
int? colorThemeIndex,
ValueGetter<List<Widget Function()>>? overlayFullScreenChild,
int? overlayFullScreenChildCount,
NetworkStatus? networkStatus,
String? networkErrorMessage,
bool? showNetworkRetry,
VersionUpdateInfo? versionUpdateInfo,
bool? showVersionUpdateBanner,
int? unreadNotificationCount,
NotificationPermissionStatus? notificationPermissionStatus,
}) {
return AppState(
appAuthStatus: appAuthStatus ?? this.appAuthStatus,
appStatus: appStatus ?? this.appStatus,
progress: progress ?? this.progress,
progressHeaderText: progressHeaderText ?? this.progressHeaderText,
currentPath: currentPath ?? this.currentPath,
colorThemeIndex: colorThemeIndex ?? this.colorThemeIndex,
overlayFullScreenChild:
overlayFullScreenChild != null ? overlayFullScreenChild() : this.overlayFullScreenChild,
overlayFullScreenChildCount: overlayFullScreenChildCount ?? this.overlayFullScreenChildCount,
networkStatus: networkStatus ?? this.networkStatus,
networkErrorMessage: networkErrorMessage ?? this.networkErrorMessage,
showNetworkRetry: showNetworkRetry ?? this.showNetworkRetry,
versionUpdateInfo: versionUpdateInfo ?? this.versionUpdateInfo,
showVersionUpdateBanner: showVersionUpdateBanner ?? this.showVersionUpdateBanner,
unreadNotificationCount: unreadNotificationCount ?? this.unreadNotificationCount,
notificationPermissionStatus: notificationPermissionStatus ?? this.notificationPermissionStatus,
);
}