copyWith method
UserFullInfo
copyWith({
- ChatPhoto? personalPhoto()?,
- ChatPhoto? photo()?,
- ChatPhoto? publicPhoto()?,
- int? communityId,
- BlockList? blockList()?,
- bool? canBeCalled,
- bool? supportsVideoCalls,
- bool? hasPrivateCalls,
- bool? hasPrivateForwards,
- bool? hasRestrictedVoiceAndVideoNoteMessages,
- bool? hasPostedToProfileStories,
- bool? hasSponsoredMessagesEnabled,
- bool? needPhoneNumberPrivacyException,
- bool? setChatBackground,
- bool? usesUnofficialApp,
- FormattedText? bio()?,
- Birthdate? birthdate()?,
- int? personalChatId,
- int? giftCount,
- int? groupInCommonCount,
- int? incomingPaidMessageStarCount,
- int? outgoingPaidMessageStarCount,
- GiftSettings? giftSettings,
- BotVerification? botVerification()?,
- ProfileTab? mainProfileTab()?,
- Audio? firstProfileAudio()?,
- UserRating? rating()?,
- UserRating? pendingRating()?,
- int? pendingRatingDate,
- FormattedText? note()?,
- TonWalletCard? tonWalletCard()?,
- BusinessInfo? businessInfo()?,
- BotInfo? botInfo()?,
- dynamic extra,
- 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
UserFullInfo copyWith({
ChatPhoto? Function()? personalPhoto,
ChatPhoto? Function()? photo,
ChatPhoto? Function()? publicPhoto,
int? communityId,
BlockList? Function()? blockList,
bool? canBeCalled,
bool? supportsVideoCalls,
bool? hasPrivateCalls,
bool? hasPrivateForwards,
bool? hasRestrictedVoiceAndVideoNoteMessages,
bool? hasPostedToProfileStories,
bool? hasSponsoredMessagesEnabled,
bool? needPhoneNumberPrivacyException,
bool? setChatBackground,
bool? usesUnofficialApp,
FormattedText? Function()? bio,
Birthdate? Function()? birthdate,
int? personalChatId,
int? giftCount,
int? groupInCommonCount,
int? incomingPaidMessageStarCount,
int? outgoingPaidMessageStarCount,
GiftSettings? giftSettings,
BotVerification? Function()? botVerification,
ProfileTab? Function()? mainProfileTab,
Audio? Function()? firstProfileAudio,
UserRating? Function()? rating,
UserRating? Function()? pendingRating,
int? pendingRatingDate,
FormattedText? Function()? note,
TonWalletCard? Function()? tonWalletCard,
ProfileShareTheme? Function()? shareTheme,
BusinessInfo? Function()? businessInfo,
BotInfo? Function()? botInfo,
dynamic extra,
int? clientId,
}) => UserFullInfo(
personalPhoto: personalPhoto != null ? personalPhoto() : this.personalPhoto,
photo: photo != null ? photo() : this.photo,
publicPhoto: publicPhoto != null ? publicPhoto() : this.publicPhoto,
communityId: communityId ?? this.communityId,
blockList: blockList != null ? blockList() : this.blockList,
canBeCalled: canBeCalled ?? this.canBeCalled,
supportsVideoCalls: supportsVideoCalls ?? this.supportsVideoCalls,
hasPrivateCalls: hasPrivateCalls ?? this.hasPrivateCalls,
hasPrivateForwards: hasPrivateForwards ?? this.hasPrivateForwards,
hasRestrictedVoiceAndVideoNoteMessages:
hasRestrictedVoiceAndVideoNoteMessages ??
this.hasRestrictedVoiceAndVideoNoteMessages,
hasPostedToProfileStories:
hasPostedToProfileStories ?? this.hasPostedToProfileStories,
hasSponsoredMessagesEnabled:
hasSponsoredMessagesEnabled ?? this.hasSponsoredMessagesEnabled,
needPhoneNumberPrivacyException:
needPhoneNumberPrivacyException ?? this.needPhoneNumberPrivacyException,
setChatBackground: setChatBackground ?? this.setChatBackground,
usesUnofficialApp: usesUnofficialApp ?? this.usesUnofficialApp,
bio: bio != null ? bio() : this.bio,
birthdate: birthdate != null ? birthdate() : this.birthdate,
personalChatId: personalChatId ?? this.personalChatId,
giftCount: giftCount ?? this.giftCount,
groupInCommonCount: groupInCommonCount ?? this.groupInCommonCount,
incomingPaidMessageStarCount:
incomingPaidMessageStarCount ?? this.incomingPaidMessageStarCount,
outgoingPaidMessageStarCount:
outgoingPaidMessageStarCount ?? this.outgoingPaidMessageStarCount,
giftSettings: giftSettings ?? this.giftSettings,
botVerification: botVerification != null
? botVerification()
: this.botVerification,
mainProfileTab: mainProfileTab != null
? mainProfileTab()
: this.mainProfileTab,
firstProfileAudio: firstProfileAudio != null
? firstProfileAudio()
: this.firstProfileAudio,
rating: rating != null ? rating() : this.rating,
pendingRating: pendingRating != null ? pendingRating() : this.pendingRating,
pendingRatingDate: pendingRatingDate ?? this.pendingRatingDate,
note: note != null ? note() : this.note,
tonWalletCard: tonWalletCard != null ? tonWalletCard() : this.tonWalletCard,
shareTheme: shareTheme != null ? shareTheme() : this.shareTheme,
businessInfo: businessInfo != null ? businessInfo() : this.businessInfo,
botInfo: botInfo != null ? botInfo() : this.botInfo,
extra: extra ?? this.extra,
clientId: clientId ?? this.clientId,
);