create static method

AttachmentMenuBot create({
  1. bool schemeUtilsIsSetDefaultData = false,
  2. String special_type = "attachmentMenuBot",
  3. String special_return_type = "attachmentMenuBot",
  4. num? bot_user_id,
  5. bool? supports_self_chat,
  6. bool? supports_user_chats,
  7. bool? supports_bot_chats,
  8. bool? supports_group_chats,
  9. bool? supports_channel_chats,
  10. bool? request_write_access,
  11. bool? is_added,
  12. bool? show_in_attachment_menu,
  13. bool? show_in_side_menu,
  14. bool? show_disclaimer_in_side_menu,
  15. String? name,
  16. AttachmentMenuBotColor? name_color,
  17. File? default_icon,
  18. File? ios_static_icon,
  19. File? ios_animated_icon,
  20. File? ios_side_menu_icon,
  21. File? android_icon,
  22. File? android_side_menu_icon,
  23. File? macos_icon,
  24. File? macos_side_menu_icon,
  25. AttachmentMenuBotColor? icon_color,
  26. File? web_app_placeholder,
})
override

Generate By General Universe Script Dont edit by hand or anything manual

Implementation

static AttachmentMenuBot create({
  bool schemeUtilsIsSetDefaultData = false,
  String special_type = "attachmentMenuBot",
  String special_return_type = "attachmentMenuBot",
  num? bot_user_id,
  bool? supports_self_chat,
  bool? supports_user_chats,
  bool? supports_bot_chats,
  bool? supports_group_chats,
  bool? supports_channel_chats,
  bool? request_write_access,
  bool? is_added,
  bool? show_in_attachment_menu,
  bool? show_in_side_menu,
  bool? show_disclaimer_in_side_menu,
  String? name,
  AttachmentMenuBotColor? name_color,
  File? default_icon,
  File? ios_static_icon,
  File? ios_animated_icon,
  File? ios_side_menu_icon,
  File? android_icon,
  File? android_side_menu_icon,
  File? macos_icon,
  File? macos_side_menu_icon,
  AttachmentMenuBotColor? icon_color,
  File? web_app_placeholder,
}) {
  // AttachmentMenuBot attachmentMenuBot = AttachmentMenuBot({
  final Map attachmentMenuBot_data_create_json = {
    "@type": special_type,
    "@return_type": special_return_type,
    "bot_user_id": bot_user_id,
    "supports_self_chat": supports_self_chat,
    "supports_user_chats": supports_user_chats,
    "supports_bot_chats": supports_bot_chats,
    "supports_group_chats": supports_group_chats,
    "supports_channel_chats": supports_channel_chats,
    "request_write_access": request_write_access,
    "is_added": is_added,
    "show_in_attachment_menu": show_in_attachment_menu,
    "show_in_side_menu": show_in_side_menu,
    "show_disclaimer_in_side_menu": show_disclaimer_in_side_menu,
    "name": name,
    "name_color": (name_color != null) ? name_color.toJson() : null,
    "default_icon": (default_icon != null) ? default_icon.toJson() : null,
    "ios_static_icon": (ios_static_icon != null) ? ios_static_icon.toJson() : null,
    "ios_animated_icon": (ios_animated_icon != null) ? ios_animated_icon.toJson() : null,
    "ios_side_menu_icon": (ios_side_menu_icon != null) ? ios_side_menu_icon.toJson() : null,
    "android_icon": (android_icon != null) ? android_icon.toJson() : null,
    "android_side_menu_icon": (android_side_menu_icon != null) ? android_side_menu_icon.toJson() : null,
    "macos_icon": (macos_icon != null) ? macos_icon.toJson() : null,
    "macos_side_menu_icon": (macos_side_menu_icon != null) ? macos_side_menu_icon.toJson() : null,
    "icon_color": (icon_color != null) ? icon_color.toJson() : null,
    "web_app_placeholder": (web_app_placeholder != null) ? web_app_placeholder.toJson() : null,
  };

  attachmentMenuBot_data_create_json.removeWhere((key, value) => value == null);

  if (schemeUtilsIsSetDefaultData) {
    defaultData.forEach((key, value) {
      if (attachmentMenuBot_data_create_json.containsKey(key) == false) {
        attachmentMenuBot_data_create_json[key] = value;
      }
    });
  }
  return AttachmentMenuBot(attachmentMenuBot_data_create_json);
}