copyWith method

WebApp copyWith({
  1. String? shortName,
  2. String? title,
  3. String? description,
  4. Photo? photo,
  5. Animation? animation()?,
})

Returns a copy with the given fields replaced. For a nullable field pass a function, e.g. field: () => null to clear it.

Implementation

WebApp copyWith({
  String? shortName,
  String? title,
  String? description,
  Photo? photo,
  Animation? Function()? animation,
}) =>
    WebApp(
      shortName: shortName ?? this.shortName,
      title: title ?? this.title,
      description: description ?? this.description,
      photo: photo ?? this.photo,
      animation: animation != null ? animation() : this.animation,
    );