copyWith method

  1. @override
PushMessageContentGiveaway copyWith({
  1. int? winnerCount,
  2. GiveawayPrize? prize()?,
  3. bool? isPinned,
})
override

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

Implementation

@override
PushMessageContentGiveaway copyWith({
  int? winnerCount,
  GiveawayPrize? Function()? prize,
  bool? isPinned,
}) => PushMessageContentGiveaway(
  winnerCount: winnerCount ?? this.winnerCount,
  prize: prize != null ? prize() : this.prize,
  isPinned: isPinned ?? this.isPinned,
);