copyWith method
AttachmentMenuBot
copyWith({
- int? botUserId,
- bool? supportsSelfChat,
- bool? supportsUserChats,
- bool? supportsBotChats,
- bool? supportsGroupChats,
- bool? supportsChannelChats,
- bool? requestWriteAccess,
- bool? isAdded,
- bool? showInAttachmentMenu,
- bool? showInSideMenu,
- bool? showDisclaimerInSideMenu,
- String? name,
- AttachmentMenuBotColor? nameColor()?,
- File? defaultIcon()?,
- File? iosStaticIcon()?,
- File? iosAnimatedIcon()?,
- File? iosSideMenuIcon()?,
- File? androidIcon()?,
- File? androidSideMenuIcon()?,
- File? macosIcon()?,
- File? macosSideMenuIcon()?,
- AttachmentMenuBotColor? iconColor()?,
- File? webAppPlaceholder()?,
- 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
AttachmentMenuBot copyWith({
int? botUserId,
bool? supportsSelfChat,
bool? supportsUserChats,
bool? supportsBotChats,
bool? supportsGroupChats,
bool? supportsChannelChats,
bool? requestWriteAccess,
bool? isAdded,
bool? showInAttachmentMenu,
bool? showInSideMenu,
bool? showDisclaimerInSideMenu,
String? name,
AttachmentMenuBotColor? Function()? nameColor,
File? Function()? defaultIcon,
File? Function()? iosStaticIcon,
File? Function()? iosAnimatedIcon,
File? Function()? iosSideMenuIcon,
File? Function()? androidIcon,
File? Function()? androidSideMenuIcon,
File? Function()? macosIcon,
File? Function()? macosSideMenuIcon,
AttachmentMenuBotColor? Function()? iconColor,
File? Function()? webAppPlaceholder,
dynamic extra,
int? clientId,
}) =>
AttachmentMenuBot(
botUserId: botUserId ?? this.botUserId,
supportsSelfChat: supportsSelfChat ?? this.supportsSelfChat,
supportsUserChats: supportsUserChats ?? this.supportsUserChats,
supportsBotChats: supportsBotChats ?? this.supportsBotChats,
supportsGroupChats: supportsGroupChats ?? this.supportsGroupChats,
supportsChannelChats: supportsChannelChats ?? this.supportsChannelChats,
requestWriteAccess: requestWriteAccess ?? this.requestWriteAccess,
isAdded: isAdded ?? this.isAdded,
showInAttachmentMenu: showInAttachmentMenu ?? this.showInAttachmentMenu,
showInSideMenu: showInSideMenu ?? this.showInSideMenu,
showDisclaimerInSideMenu:
showDisclaimerInSideMenu ?? this.showDisclaimerInSideMenu,
name: name ?? this.name,
nameColor: nameColor != null ? nameColor() : this.nameColor,
defaultIcon: defaultIcon != null ? defaultIcon() : this.defaultIcon,
iosStaticIcon:
iosStaticIcon != null ? iosStaticIcon() : this.iosStaticIcon,
iosAnimatedIcon:
iosAnimatedIcon != null ? iosAnimatedIcon() : this.iosAnimatedIcon,
iosSideMenuIcon:
iosSideMenuIcon != null ? iosSideMenuIcon() : this.iosSideMenuIcon,
androidIcon: androidIcon != null ? androidIcon() : this.androidIcon,
androidSideMenuIcon: androidSideMenuIcon != null
? androidSideMenuIcon()
: this.androidSideMenuIcon,
macosIcon: macosIcon != null ? macosIcon() : this.macosIcon,
macosSideMenuIcon: macosSideMenuIcon != null
? macosSideMenuIcon()
: this.macosSideMenuIcon,
iconColor: iconColor != null ? iconColor() : this.iconColor,
webAppPlaceholder: webAppPlaceholder != null
? webAppPlaceholder()
: this.webAppPlaceholder,
extra: extra ?? this.extra,
clientId: clientId ?? this.clientId,
);