copyWith method

Sticker copyWith({
  1. int? id,
  2. int? setId,
  3. int? width,
  4. int? height,
  5. String? emoji,
  6. StickerFormat? format,
  7. StickerFullType? fullType,
  8. Thumbnail? thumbnail()?,
  9. File? sticker,
  10. dynamic extra,
  11. 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

Sticker copyWith({
  int? id,
  int? setId,
  int? width,
  int? height,
  String? emoji,
  StickerFormat? format,
  StickerFullType? fullType,
  Thumbnail? Function()? thumbnail,
  File? sticker,
  dynamic extra,
  int? clientId,
}) => Sticker(
  id: id ?? this.id,
  setId: setId ?? this.setId,
  width: width ?? this.width,
  height: height ?? this.height,
  emoji: emoji ?? this.emoji,
  format: format ?? this.format,
  fullType: fullType ?? this.fullType,
  thumbnail: thumbnail != null ? thumbnail() : this.thumbnail,
  sticker: sticker ?? this.sticker,
  extra: extra ?? this.extra,
  clientId: clientId ?? this.clientId,
);