copyWith method Null safety

ImageConfiguration copyWith(
  1. {AssetBundle? bundle,
  2. double? devicePixelRatio,
  3. Locale? locale,
  4. TextDirection? textDirection,
  5. Size? size,
  6. TargetPlatform? platform}

Creates an object holding the configuration information for an ImageProvider.

All the arguments are optional. Configuration information is merely advisory and best-effort.


ImageConfiguration copyWith({
  AssetBundle? bundle,
  double? devicePixelRatio,
  Locale? locale,
  TextDirection? textDirection,
  Size? size,
  TargetPlatform? platform,
}) {
  return ImageConfiguration(
    bundle: bundle ?? this.bundle,
    devicePixelRatio: devicePixelRatio ?? this.devicePixelRatio,
    locale: locale ?? this.locale,
    textDirection: textDirection ?? this.textDirection,
    size: size ?? this.size,
    platform: platform ?? this.platform,