copyWith method

AnimatedEmoji copyWith({
  1. Sticker? sticker()?,
  2. int? stickerWidth,
  3. int? stickerHeight,
  4. int? fitzpatrickType,
  5. File? sound()?,
  6. bool? isRegularEmoji,
  7. dynamic extra,
  8. int? clientId,
})

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

Implementation

AnimatedEmoji copyWith({
  Sticker? Function()? sticker,
  int? stickerWidth,
  int? stickerHeight,
  int? fitzpatrickType,
  File? Function()? sound,
  bool? isRegularEmoji,
  dynamic extra,
  int? clientId,
}) => AnimatedEmoji(
  sticker: sticker != null ? sticker() : this.sticker,
  stickerWidth: stickerWidth ?? this.stickerWidth,
  stickerHeight: stickerHeight ?? this.stickerHeight,
  fitzpatrickType: fitzpatrickType ?? this.fitzpatrickType,
  sound: sound != null ? sound() : this.sound,
  isRegularEmoji: isRegularEmoji ?? this.isRegularEmoji,
  extra: extra ?? this.extra,
  clientId: clientId ?? this.clientId,
);