copyWith method
InputPaidMedia
copyWith({
- InputPaidMediaType? type,
- InputFile? media,
- InputThumbnail? thumbnail()?,
- List<
int> ? addedStickerFileIds, - int? width,
- int? height,
Returns a copy with the given fields replaced. For a nullable
field pass a function, e.g. field: () => null to clear it.
Implementation
InputPaidMedia copyWith({
InputPaidMediaType? type,
InputFile? media,
InputThumbnail? Function()? thumbnail,
List<int>? addedStickerFileIds,
int? width,
int? height,
}) => InputPaidMedia(
type: type ?? this.type,
media: media ?? this.media,
thumbnail: thumbnail != null ? thumbnail() : this.thumbnail,
addedStickerFileIds: addedStickerFileIds ?? this.addedStickerFileIds,
width: width ?? this.width,
height: height ?? this.height,
);