create static method

NotificationSettingsScope create({
  1. bool schemeUtilsIsSetDefaultData = false,
  2. String special_type = "notificationSettingsScope",
  3. bool special_is_json_scheme_class = true,
  4. String special_return_type = "notificationSettingsScope",
  5. NotificationSettingsScopePrivateChats? notification_settings_scope_private_chats,
  6. NotificationSettingsScopeGroupChats? notification_settings_scope_group_chats,
  7. NotificationSettingsScopeChannelChats? notification_settings_scope_channel_chats,
})
override

Generate By AZKADEV | Azka Axelion Gibran Script Dont edit by hand or anything manual

Implementation

static NotificationSettingsScope create({
  bool schemeUtilsIsSetDefaultData = false,
  String special_type = "notificationSettingsScope",
  bool special_is_json_scheme_class = true,
  String special_return_type = "notificationSettingsScope",
  NotificationSettingsScopePrivateChats? notification_settings_scope_private_chats,
  NotificationSettingsScopeGroupChats? notification_settings_scope_group_chats,
  NotificationSettingsScopeChannelChats? notification_settings_scope_channel_chats,
}) {
  // NotificationSettingsScope notificationSettingsScope = NotificationSettingsScope({
  final Map notificationSettingsScope_data_create_json = {
    "@type": special_type,
    "@is_json_scheme_class": special_is_json_scheme_class,
    "@return_type": special_return_type,
    "notification_settings_scope_private_chats": (notification_settings_scope_private_chats != null) ? notification_settings_scope_private_chats.toJson() : null,
    "notification_settings_scope_group_chats": (notification_settings_scope_group_chats != null) ? notification_settings_scope_group_chats.toJson() : null,
    "notification_settings_scope_channel_chats": (notification_settings_scope_channel_chats != null) ? notification_settings_scope_channel_chats.toJson() : null,
  };

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

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