copyWith method
Returns a copy with the given fields replaced. For a nullable
field pass a function, e.g. field: () => null to clear it.
Implementation
TonNft copyWith({
String? collectionAddress,
String? address,
String? ownerAddress,
String? index,
String? name,
String? description,
PhotoSize? Function()? image,
PhotoSize? Function()? thumbnail,
Document? Function()? content,
Sticker? Function()? sticker,
List<TonNftAttribute>? attributes,
JsonValue? Function()? extraValue,
UpgradedGift? Function()? gift,
}) => TonNft(
collectionAddress: collectionAddress ?? this.collectionAddress,
address: address ?? this.address,
ownerAddress: ownerAddress ?? this.ownerAddress,
index: index ?? this.index,
name: name ?? this.name,
description: description ?? this.description,
image: image != null ? image() : this.image,
thumbnail: thumbnail != null ? thumbnail() : this.thumbnail,
content: content != null ? content() : this.content,
sticker: sticker != null ? sticker() : this.sticker,
attributes: attributes ?? this.attributes,
extraValue: extraValue != null ? extraValue() : this.extraValue,
gift: gift != null ? gift() : this.gift,
);