package com.airlock.iam.admin.application.service.settings;

import com.airlock.iam.admin.domain.model.user.UserLockedVisibility;
import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Collections;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
import java.util.Map.Entry;

@SuppressFBWarnings("UWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTOR")
public class UserDetailSettings {
   private boolean editable;
   private boolean showUserValidSection;
   private boolean showRememberMeSection;
   private boolean allowsUsernameChange;
   private boolean generateUsername;
   private String usernameField;
   private String usernamePrefill;
   private List<String> availableUserRoles;
   private List<UserProfileItemSettings> rowsOnUserDetailPage;
   private List<String> lockReasons;
   private boolean showAuthMethodMigrationSection;
   private List<UserProfileItemSettings> overviewProfileItems;
   private boolean enableMultipleNextAuthMethods;
   private Map<String, String> authMethodNameToId;
   private List<String> visibleAuthMethodIds;
   private List<String> possibleNextAuthMethods;
   private List<String> genericAuthenticationMethodIds;
   private List<String> userManagementExtensionIds;
   private UserLockedVisibility userLockedVisibility;
   private boolean showAuthenticationMethodManagement;
   private boolean showTempLockingSection;
   private boolean showAccountLinkTab;
   private Map<String, Object> tokenSettings;
   private boolean hasUserTrailLogDatabaseConnection;
   private boolean deletionAllowed;

   @SuppressFBWarnings(justification = "generated code")
   public static UserDetailSettings.UserDetailSettingsBuilder builder() {
      return new UserDetailSettings.UserDetailSettingsBuilder();
   }

   @SuppressFBWarnings(justification = "generated code")
   public boolean isEditable() {
      return this.editable;
   }

   @SuppressFBWarnings(justification = "generated code")
   public boolean isShowUserValidSection() {
      return this.showUserValidSection;
   }

   @SuppressFBWarnings(justification = "generated code")
   public boolean isShowRememberMeSection() {
      return this.showRememberMeSection;
   }

   @SuppressFBWarnings(justification = "generated code")
   public boolean isAllowsUsernameChange() {
      return this.allowsUsernameChange;
   }

   @SuppressFBWarnings(justification = "generated code")
   public boolean isGenerateUsername() {
      return this.generateUsername;
   }

   @SuppressFBWarnings(justification = "generated code")
   public String getUsernameField() {
      return this.usernameField;
   }

   @SuppressFBWarnings(justification = "generated code")
   public String getUsernamePrefill() {
      return this.usernamePrefill;
   }

   @SuppressFBWarnings(justification = "generated code")
   public List<String> getAvailableUserRoles() {
      return this.availableUserRoles;
   }

   @SuppressFBWarnings(justification = "generated code")
   public List<UserProfileItemSettings> getRowsOnUserDetailPage() {
      return this.rowsOnUserDetailPage;
   }

   @SuppressFBWarnings(justification = "generated code")
   public List<String> getLockReasons() {
      return this.lockReasons;
   }

   @SuppressFBWarnings(justification = "generated code")
   public boolean isShowAuthMethodMigrationSection() {
      return this.showAuthMethodMigrationSection;
   }

   @SuppressFBWarnings(justification = "generated code")
   public List<UserProfileItemSettings> getOverviewProfileItems() {
      return this.overviewProfileItems;
   }

   @SuppressFBWarnings(justification = "generated code")
   public boolean isEnableMultipleNextAuthMethods() {
      return this.enableMultipleNextAuthMethods;
   }

   @SuppressFBWarnings(justification = "generated code")
   public Map<String, String> getAuthMethodNameToId() {
      return this.authMethodNameToId;
   }

   @SuppressFBWarnings(justification = "generated code")
   public List<String> getVisibleAuthMethodIds() {
      return this.visibleAuthMethodIds;
   }

   @SuppressFBWarnings(justification = "generated code")
   public List<String> getPossibleNextAuthMethods() {
      return this.possibleNextAuthMethods;
   }

   @SuppressFBWarnings(justification = "generated code")
   public List<String> getGenericAuthenticationMethodIds() {
      return this.genericAuthenticationMethodIds;
   }

   @SuppressFBWarnings(justification = "generated code")
   public List<String> getUserManagementExtensionIds() {
      return this.userManagementExtensionIds;
   }

   @SuppressFBWarnings(justification = "generated code")
   public UserLockedVisibility getUserLockedVisibility() {
      return this.userLockedVisibility;
   }

   @SuppressFBWarnings(justification = "generated code")
   public boolean isShowAuthenticationMethodManagement() {
      return this.showAuthenticationMethodManagement;
   }

   @SuppressFBWarnings(justification = "generated code")
   public boolean isShowTempLockingSection() {
      return this.showTempLockingSection;
   }

   @SuppressFBWarnings(justification = "generated code")
   public boolean isShowAccountLinkTab() {
      return this.showAccountLinkTab;
   }

   @SuppressFBWarnings(justification = "generated code")
   public Map<String, Object> getTokenSettings() {
      return this.tokenSettings;
   }

   @SuppressFBWarnings(justification = "generated code")
   public boolean isHasUserTrailLogDatabaseConnection() {
      return this.hasUserTrailLogDatabaseConnection;
   }

   @SuppressFBWarnings(justification = "generated code")
   public boolean isDeletionAllowed() {
      return this.deletionAllowed;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setEditable(boolean editable) {
      this.editable = editable;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setShowUserValidSection(boolean showUserValidSection) {
      this.showUserValidSection = showUserValidSection;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setShowRememberMeSection(boolean showRememberMeSection) {
      this.showRememberMeSection = showRememberMeSection;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setAllowsUsernameChange(boolean allowsUsernameChange) {
      this.allowsUsernameChange = allowsUsernameChange;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setGenerateUsername(boolean generateUsername) {
      this.generateUsername = generateUsername;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setUsernameField(String usernameField) {
      this.usernameField = usernameField;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setUsernamePrefill(String usernamePrefill) {
      this.usernamePrefill = usernamePrefill;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setAvailableUserRoles(List<String> availableUserRoles) {
      this.availableUserRoles = availableUserRoles;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setRowsOnUserDetailPage(List<UserProfileItemSettings> rowsOnUserDetailPage) {
      this.rowsOnUserDetailPage = rowsOnUserDetailPage;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setLockReasons(List<String> lockReasons) {
      this.lockReasons = lockReasons;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setShowAuthMethodMigrationSection(boolean showAuthMethodMigrationSection) {
      this.showAuthMethodMigrationSection = showAuthMethodMigrationSection;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setOverviewProfileItems(List<UserProfileItemSettings> overviewProfileItems) {
      this.overviewProfileItems = overviewProfileItems;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setEnableMultipleNextAuthMethods(boolean enableMultipleNextAuthMethods) {
      this.enableMultipleNextAuthMethods = enableMultipleNextAuthMethods;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setAuthMethodNameToId(Map<String, String> authMethodNameToId) {
      this.authMethodNameToId = authMethodNameToId;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setVisibleAuthMethodIds(List<String> visibleAuthMethodIds) {
      this.visibleAuthMethodIds = visibleAuthMethodIds;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setPossibleNextAuthMethods(List<String> possibleNextAuthMethods) {
      this.possibleNextAuthMethods = possibleNextAuthMethods;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setGenericAuthenticationMethodIds(List<String> genericAuthenticationMethodIds) {
      this.genericAuthenticationMethodIds = genericAuthenticationMethodIds;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setUserManagementExtensionIds(List<String> userManagementExtensionIds) {
      this.userManagementExtensionIds = userManagementExtensionIds;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setUserLockedVisibility(UserLockedVisibility userLockedVisibility) {
      this.userLockedVisibility = userLockedVisibility;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setShowAuthenticationMethodManagement(boolean showAuthenticationMethodManagement) {
      this.showAuthenticationMethodManagement = showAuthenticationMethodManagement;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setShowTempLockingSection(boolean showTempLockingSection) {
      this.showTempLockingSection = showTempLockingSection;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setShowAccountLinkTab(boolean showAccountLinkTab) {
      this.showAccountLinkTab = showAccountLinkTab;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setTokenSettings(Map<String, Object> tokenSettings) {
      this.tokenSettings = tokenSettings;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setHasUserTrailLogDatabaseConnection(boolean hasUserTrailLogDatabaseConnection) {
      this.hasUserTrailLogDatabaseConnection = hasUserTrailLogDatabaseConnection;
   }

   @SuppressFBWarnings(justification = "generated code")
   public void setDeletionAllowed(boolean deletionAllowed) {
      this.deletionAllowed = deletionAllowed;
   }

   @SuppressFBWarnings(justification = "generated code")
   @Override
   public boolean equals(Object o) {
      if (o == this) {
         return true;
      } else if (!(o instanceof UserDetailSettings other)) {
         return false;
      } else {
         if (!other.canEqual(this)) {
            return false;
         }

         if (this.editable != other.editable) {
            return false;
         }

         if (this.showUserValidSection != other.showUserValidSection) {
            return false;
         }

         if (this.showRememberMeSection != other.showRememberMeSection) {
            return false;
         }

         if (this.allowsUsernameChange != other.allowsUsernameChange) {
            return false;
         }

         if (this.generateUsername != other.generateUsername) {
            return false;
         }

         if (this.showAuthMethodMigrationSection != other.showAuthMethodMigrationSection) {
            return false;
         }

         if (this.enableMultipleNextAuthMethods != other.enableMultipleNextAuthMethods) {
            return false;
         }

         if (this.showAuthenticationMethodManagement != other.showAuthenticationMethodManagement) {
            return false;
         }

         if (this.showTempLockingSection != other.showTempLockingSection) {
            return false;
         }

         if (this.showAccountLinkTab != other.showAccountLinkTab) {
            return false;
         }

         if (this.hasUserTrailLogDatabaseConnection != other.hasUserTrailLogDatabaseConnection) {
            return false;
         }

         if (this.deletionAllowed != other.deletionAllowed) {
            return false;
         }

         Object this$usernameField = this.usernameField;
         Object other$usernameField = other.usernameField;
         if (this$usernameField == null ? other$usernameField == null : this$usernameField.equals(other$usernameField)) {
            Object this$usernamePrefill = this.usernamePrefill;
            Object other$usernamePrefill = other.usernamePrefill;
            if (this$usernamePrefill == null ? other$usernamePrefill == null : this$usernamePrefill.equals(other$usernamePrefill)) {
               Object this$availableUserRoles = this.availableUserRoles;
               Object other$availableUserRoles = other.availableUserRoles;
               if (this$availableUserRoles == null ? other$availableUserRoles == null : this$availableUserRoles.equals(other$availableUserRoles)) {
                  Object this$rowsOnUserDetailPage = this.rowsOnUserDetailPage;
                  Object other$rowsOnUserDetailPage = other.rowsOnUserDetailPage;
                  if (this$rowsOnUserDetailPage == null ? other$rowsOnUserDetailPage == null : this$rowsOnUserDetailPage.equals(other$rowsOnUserDetailPage)) {
                     Object this$lockReasons = this.lockReasons;
                     Object other$lockReasons = other.lockReasons;
                     if (this$lockReasons == null ? other$lockReasons == null : this$lockReasons.equals(other$lockReasons)) {
                        Object this$overviewProfileItems = this.overviewProfileItems;
                        Object other$overviewProfileItems = other.overviewProfileItems;
                        if (this$overviewProfileItems == null
                           ? other$overviewProfileItems == null
                           : this$overviewProfileItems.equals(other$overviewProfileItems)) {
                           Object this$authMethodNameToId = this.authMethodNameToId;
                           Object other$authMethodNameToId = other.authMethodNameToId;
                           if (this$authMethodNameToId == null ? other$authMethodNameToId == null : this$authMethodNameToId.equals(other$authMethodNameToId)) {
                              Object this$visibleAuthMethodIds = this.visibleAuthMethodIds;
                              Object other$visibleAuthMethodIds = other.visibleAuthMethodIds;
                              if (this$visibleAuthMethodIds == null
                                 ? other$visibleAuthMethodIds == null
                                 : this$visibleAuthMethodIds.equals(other$visibleAuthMethodIds)) {
                                 Object this$possibleNextAuthMethods = this.possibleNextAuthMethods;
                                 Object other$possibleNextAuthMethods = other.possibleNextAuthMethods;
                                 if (this$possibleNextAuthMethods == null
                                    ? other$possibleNextAuthMethods == null
                                    : this$possibleNextAuthMethods.equals(other$possibleNextAuthMethods)) {
                                    Object this$genericAuthenticationMethodIds = this.genericAuthenticationMethodIds;
                                    Object other$genericAuthenticationMethodIds = other.genericAuthenticationMethodIds;
                                    if (this$genericAuthenticationMethodIds == null
                                       ? other$genericAuthenticationMethodIds == null
                                       : this$genericAuthenticationMethodIds.equals(other$genericAuthenticationMethodIds)) {
                                       Object this$userManagementExtensionIds = this.userManagementExtensionIds;
                                       Object other$userManagementExtensionIds = other.userManagementExtensionIds;
                                       if (this$userManagementExtensionIds == null
                                          ? other$userManagementExtensionIds == null
                                          : this$userManagementExtensionIds.equals(other$userManagementExtensionIds)) {
                                          Object this$userLockedVisibility = this.userLockedVisibility;
                                          Object other$userLockedVisibility = other.userLockedVisibility;
                                          if (this$userLockedVisibility == null
                                             ? other$userLockedVisibility == null
                                             : this$userLockedVisibility.equals(other$userLockedVisibility)) {
                                             Object this$tokenSettings = this.tokenSettings;
                                             Object other$tokenSettings = other.tokenSettings;
                                             return this$tokenSettings == null ? other$tokenSettings == null : this$tokenSettings.equals(other$tokenSettings);
                                          } else {
                                             return false;
                                          }
                                       } else {
                                          return false;
                                       }
                                    } else {
                                       return false;
                                    }
                                 } else {
                                    return false;
                                 }
                              } else {
                                 return false;
                              }
                           } else {
                              return false;
                           }
                        } else {
                           return false;
                        }
                     } else {
                        return false;
                     }
                  } else {
                     return false;
                  }
               } else {
                  return false;
               }
            } else {
               return false;
            }
         } else {
            return false;
         }
      }
   }

   @SuppressFBWarnings(justification = "generated code")
   protected boolean canEqual(Object other) {
      return other instanceof UserDetailSettings;
   }

   @SuppressFBWarnings(justification = "generated code")
   @Override
   public int hashCode() {
      int PRIME = 59;
      int result = 1;
      result = result * 59 + (this.editable ? 79 : 97);
      result = result * 59 + (this.showUserValidSection ? 79 : 97);
      result = result * 59 + (this.showRememberMeSection ? 79 : 97);
      result = result * 59 + (this.allowsUsernameChange ? 79 : 97);
      result = result * 59 + (this.generateUsername ? 79 : 97);
      result = result * 59 + (this.showAuthMethodMigrationSection ? 79 : 97);
      result = result * 59 + (this.enableMultipleNextAuthMethods ? 79 : 97);
      result = result * 59 + (this.showAuthenticationMethodManagement ? 79 : 97);
      result = result * 59 + (this.showTempLockingSection ? 79 : 97);
      result = result * 59 + (this.showAccountLinkTab ? 79 : 97);
      result = result * 59 + (this.hasUserTrailLogDatabaseConnection ? 79 : 97);
      result = result * 59 + (this.deletionAllowed ? 79 : 97);
      Object $usernameField = this.usernameField;
      result = result * 59 + ($usernameField == null ? 43 : $usernameField.hashCode());
      Object $usernamePrefill = this.usernamePrefill;
      result = result * 59 + ($usernamePrefill == null ? 43 : $usernamePrefill.hashCode());
      Object $availableUserRoles = this.availableUserRoles;
      result = result * 59 + ($availableUserRoles == null ? 43 : $availableUserRoles.hashCode());
      Object $rowsOnUserDetailPage = this.rowsOnUserDetailPage;
      result = result * 59 + ($rowsOnUserDetailPage == null ? 43 : $rowsOnUserDetailPage.hashCode());
      Object $lockReasons = this.lockReasons;
      result = result * 59 + ($lockReasons == null ? 43 : $lockReasons.hashCode());
      Object $overviewProfileItems = this.overviewProfileItems;
      result = result * 59 + ($overviewProfileItems == null ? 43 : $overviewProfileItems.hashCode());
      Object $authMethodNameToId = this.authMethodNameToId;
      result = result * 59 + ($authMethodNameToId == null ? 43 : $authMethodNameToId.hashCode());
      Object $visibleAuthMethodIds = this.visibleAuthMethodIds;
      result = result * 59 + ($visibleAuthMethodIds == null ? 43 : $visibleAuthMethodIds.hashCode());
      Object $possibleNextAuthMethods = this.possibleNextAuthMethods;
      result = result * 59 + ($possibleNextAuthMethods == null ? 43 : $possibleNextAuthMethods.hashCode());
      Object $genericAuthenticationMethodIds = this.genericAuthenticationMethodIds;
      result = result * 59 + ($genericAuthenticationMethodIds == null ? 43 : $genericAuthenticationMethodIds.hashCode());
      Object $userManagementExtensionIds = this.userManagementExtensionIds;
      result = result * 59 + ($userManagementExtensionIds == null ? 43 : $userManagementExtensionIds.hashCode());
      Object $userLockedVisibility = this.userLockedVisibility;
      result = result * 59 + ($userLockedVisibility == null ? 43 : $userLockedVisibility.hashCode());
      Object $tokenSettings = this.tokenSettings;
      return result * 59 + ($tokenSettings == null ? 43 : $tokenSettings.hashCode());
   }

   @SuppressFBWarnings(justification = "generated code")
   @Override
   public String toString() {
      return "UserDetailSettings(editable="
         + this.isEditable()
         + ", showUserValidSection="
         + this.isShowUserValidSection()
         + ", showRememberMeSection="
         + this.isShowRememberMeSection()
         + ", allowsUsernameChange="
         + this.isAllowsUsernameChange()
         + ", generateUsername="
         + this.isGenerateUsername()
         + ", usernameField="
         + this.getUsernameField()
         + ", usernamePrefill="
         + this.getUsernamePrefill()
         + ", availableUserRoles="
         + this.getAvailableUserRoles()
         + ", rowsOnUserDetailPage="
         + this.getRowsOnUserDetailPage()
         + ", lockReasons="
         + this.getLockReasons()
         + ", showAuthMethodMigrationSection="
         + this.isShowAuthMethodMigrationSection()
         + ", overviewProfileItems="
         + this.getOverviewProfileItems()
         + ", enableMultipleNextAuthMethods="
         + this.isEnableMultipleNextAuthMethods()
         + ", authMethodNameToId="
         + this.getAuthMethodNameToId()
         + ", visibleAuthMethodIds="
         + this.getVisibleAuthMethodIds()
         + ", possibleNextAuthMethods="
         + this.getPossibleNextAuthMethods()
         + ", genericAuthenticationMethodIds="
         + this.getGenericAuthenticationMethodIds()
         + ", userManagementExtensionIds="
         + this.getUserManagementExtensionIds()
         + ", userLockedVisibility="
         + this.getUserLockedVisibility()
         + ", showAuthenticationMethodManagement="
         + this.isShowAuthenticationMethodManagement()
         + ", showTempLockingSection="
         + this.isShowTempLockingSection()
         + ", showAccountLinkTab="
         + this.isShowAccountLinkTab()
         + ", tokenSettings="
         + this.getTokenSettings()
         + ", hasUserTrailLogDatabaseConnection="
         + this.isHasUserTrailLogDatabaseConnection()
         + ", deletionAllowed="
         + this.isDeletionAllowed()
         + ")";
   }

   @SuppressFBWarnings(justification = "generated code")
   public UserDetailSettings(
      boolean editable,
      boolean showUserValidSection,
      boolean showRememberMeSection,
      boolean allowsUsernameChange,
      boolean generateUsername,
      String usernameField,
      String usernamePrefill,
      List<String> availableUserRoles,
      List<UserProfileItemSettings> rowsOnUserDetailPage,
      List<String> lockReasons,
      boolean showAuthMethodMigrationSection,
      List<UserProfileItemSettings> overviewProfileItems,
      boolean enableMultipleNextAuthMethods,
      Map<String, String> authMethodNameToId,
      List<String> visibleAuthMethodIds,
      List<String> possibleNextAuthMethods,
      List<String> genericAuthenticationMethodIds,
      List<String> userManagementExtensionIds,
      UserLockedVisibility userLockedVisibility,
      boolean showAuthenticationMethodManagement,
      boolean showTempLockingSection,
      boolean showAccountLinkTab,
      Map<String, Object> tokenSettings,
      boolean hasUserTrailLogDatabaseConnection,
      boolean deletionAllowed
   ) {
      this.editable = editable;
      this.showUserValidSection = showUserValidSection;
      this.showRememberMeSection = showRememberMeSection;
      this.allowsUsernameChange = allowsUsernameChange;
      this.generateUsername = generateUsername;
      this.usernameField = usernameField;
      this.usernamePrefill = usernamePrefill;
      this.availableUserRoles = availableUserRoles;
      this.rowsOnUserDetailPage = rowsOnUserDetailPage;
      this.lockReasons = lockReasons;
      this.showAuthMethodMigrationSection = showAuthMethodMigrationSection;
      this.overviewProfileItems = overviewProfileItems;
      this.enableMultipleNextAuthMethods = enableMultipleNextAuthMethods;
      this.authMethodNameToId = authMethodNameToId;
      this.visibleAuthMethodIds = visibleAuthMethodIds;
      this.possibleNextAuthMethods = possibleNextAuthMethods;
      this.genericAuthenticationMethodIds = genericAuthenticationMethodIds;
      this.userManagementExtensionIds = userManagementExtensionIds;
      this.userLockedVisibility = userLockedVisibility;
      this.showAuthenticationMethodManagement = showAuthenticationMethodManagement;
      this.showTempLockingSection = showTempLockingSection;
      this.showAccountLinkTab = showAccountLinkTab;
      this.tokenSettings = tokenSettings;
      this.hasUserTrailLogDatabaseConnection = hasUserTrailLogDatabaseConnection;
      this.deletionAllowed = deletionAllowed;
   }

   @SuppressFBWarnings(justification = "generated code")
   public UserDetailSettings() {
   }

   @SuppressFBWarnings(justification = "generated code")
   public static class UserDetailSettingsBuilder {
      @SuppressFBWarnings(justification = "generated code")
      private boolean editable;
      @SuppressFBWarnings(justification = "generated code")
      private boolean showUserValidSection;
      @SuppressFBWarnings(justification = "generated code")
      private boolean showRememberMeSection;
      @SuppressFBWarnings(justification = "generated code")
      private boolean allowsUsernameChange;
      @SuppressFBWarnings(justification = "generated code")
      private boolean generateUsername;
      @SuppressFBWarnings(justification = "generated code")
      private String usernameField;
      @SuppressFBWarnings(justification = "generated code")
      private String usernamePrefill;
      @SuppressFBWarnings(justification = "generated code")
      private ArrayList<String> availableUserRoles;
      @SuppressFBWarnings(justification = "generated code")
      private ArrayList<UserProfileItemSettings> rowsOnUserDetailPage;
      @SuppressFBWarnings(justification = "generated code")
      private ArrayList<String> lockReasons;
      @SuppressFBWarnings(justification = "generated code")
      private boolean showAuthMethodMigrationSection;
      @SuppressFBWarnings(justification = "generated code")
      private ArrayList<UserProfileItemSettings> overviewProfileItems;
      @SuppressFBWarnings(justification = "generated code")
      private boolean enableMultipleNextAuthMethods;
      @SuppressFBWarnings(justification = "generated code")
      private Map<String, String> authMethodNameToId;
      @SuppressFBWarnings(justification = "generated code")
      private List<String> visibleAuthMethodIds;
      @SuppressFBWarnings(justification = "generated code")
      private ArrayList<String> possibleNextAuthMethods;
      @SuppressFBWarnings(justification = "generated code")
      private ArrayList<String> genericAuthenticationMethodIds;
      @SuppressFBWarnings(justification = "generated code")
      private ArrayList<String> userManagementExtensionIds;
      @SuppressFBWarnings(justification = "generated code")
      private UserLockedVisibility userLockedVisibility;
      @SuppressFBWarnings(justification = "generated code")
      private boolean showAuthenticationMethodManagement;
      @SuppressFBWarnings(justification = "generated code")
      private boolean showTempLockingSection;
      @SuppressFBWarnings(justification = "generated code")
      private boolean showAccountLinkTab;
      @SuppressFBWarnings(justification = "generated code")
      private ArrayList<String> tokenSettings$key;
      @SuppressFBWarnings(justification = "generated code")
      private ArrayList<Object> tokenSettings$value;
      @SuppressFBWarnings(justification = "generated code")
      private boolean hasUserTrailLogDatabaseConnection;
      @SuppressFBWarnings(justification = "generated code")
      private boolean deletionAllowed;

      @SuppressFBWarnings(justification = "generated code")
      UserDetailSettingsBuilder() {
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder editable(boolean editable) {
         this.editable = editable;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder showUserValidSection(boolean showUserValidSection) {
         this.showUserValidSection = showUserValidSection;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder showRememberMeSection(boolean showRememberMeSection) {
         this.showRememberMeSection = showRememberMeSection;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder allowsUsernameChange(boolean allowsUsernameChange) {
         this.allowsUsernameChange = allowsUsernameChange;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder generateUsername(boolean generateUsername) {
         this.generateUsername = generateUsername;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder usernameField(String usernameField) {
         this.usernameField = usernameField;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder usernamePrefill(String usernamePrefill) {
         this.usernamePrefill = usernamePrefill;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder availableUserRole(String availableUserRole) {
         if (this.availableUserRoles == null) {
            this.availableUserRoles = new ArrayList<>();
         }

         this.availableUserRoles.add(availableUserRole);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder availableUserRoles(Collection<? extends String> availableUserRoles) {
         if (availableUserRoles == null) {
            throw new NullPointerException("availableUserRoles cannot be null");
         }

         if (this.availableUserRoles == null) {
            this.availableUserRoles = new ArrayList<>();
         }

         this.availableUserRoles.addAll(availableUserRoles);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder clearAvailableUserRoles() {
         if (this.availableUserRoles != null) {
            this.availableUserRoles.clear();
         }

         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder rowOnUserDetailPage(UserProfileItemSettings rowOnUserDetailPage) {
         if (this.rowsOnUserDetailPage == null) {
            this.rowsOnUserDetailPage = new ArrayList<>();
         }

         this.rowsOnUserDetailPage.add(rowOnUserDetailPage);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder rowsOnUserDetailPage(Collection<? extends UserProfileItemSettings> rowsOnUserDetailPage) {
         if (rowsOnUserDetailPage == null) {
            throw new NullPointerException("rowsOnUserDetailPage cannot be null");
         }

         if (this.rowsOnUserDetailPage == null) {
            this.rowsOnUserDetailPage = new ArrayList<>();
         }

         this.rowsOnUserDetailPage.addAll(rowsOnUserDetailPage);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder clearRowsOnUserDetailPage() {
         if (this.rowsOnUserDetailPage != null) {
            this.rowsOnUserDetailPage.clear();
         }

         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder lockReason(String lockReason) {
         if (this.lockReasons == null) {
            this.lockReasons = new ArrayList<>();
         }

         this.lockReasons.add(lockReason);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder lockReasons(Collection<? extends String> lockReasons) {
         if (lockReasons == null) {
            throw new NullPointerException("lockReasons cannot be null");
         }

         if (this.lockReasons == null) {
            this.lockReasons = new ArrayList<>();
         }

         this.lockReasons.addAll(lockReasons);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder clearLockReasons() {
         if (this.lockReasons != null) {
            this.lockReasons.clear();
         }

         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder showAuthMethodMigrationSection(boolean showAuthMethodMigrationSection) {
         this.showAuthMethodMigrationSection = showAuthMethodMigrationSection;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder overviewProfileItem(UserProfileItemSettings overviewProfileItem) {
         if (this.overviewProfileItems == null) {
            this.overviewProfileItems = new ArrayList<>();
         }

         this.overviewProfileItems.add(overviewProfileItem);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder overviewProfileItems(Collection<? extends UserProfileItemSettings> overviewProfileItems) {
         if (overviewProfileItems == null) {
            throw new NullPointerException("overviewProfileItems cannot be null");
         }

         if (this.overviewProfileItems == null) {
            this.overviewProfileItems = new ArrayList<>();
         }

         this.overviewProfileItems.addAll(overviewProfileItems);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder clearOverviewProfileItems() {
         if (this.overviewProfileItems != null) {
            this.overviewProfileItems.clear();
         }

         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder enableMultipleNextAuthMethods(boolean enableMultipleNextAuthMethods) {
         this.enableMultipleNextAuthMethods = enableMultipleNextAuthMethods;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder authMethodNameToId(Map<String, String> authMethodNameToId) {
         this.authMethodNameToId = authMethodNameToId;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder visibleAuthMethodIds(List<String> visibleAuthMethodIds) {
         this.visibleAuthMethodIds = visibleAuthMethodIds;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder possibleNextAuthMethod(String possibleNextAuthMethod) {
         if (this.possibleNextAuthMethods == null) {
            this.possibleNextAuthMethods = new ArrayList<>();
         }

         this.possibleNextAuthMethods.add(possibleNextAuthMethod);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder possibleNextAuthMethods(Collection<? extends String> possibleNextAuthMethods) {
         if (possibleNextAuthMethods == null) {
            throw new NullPointerException("possibleNextAuthMethods cannot be null");
         }

         if (this.possibleNextAuthMethods == null) {
            this.possibleNextAuthMethods = new ArrayList<>();
         }

         this.possibleNextAuthMethods.addAll(possibleNextAuthMethods);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder clearPossibleNextAuthMethods() {
         if (this.possibleNextAuthMethods != null) {
            this.possibleNextAuthMethods.clear();
         }

         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder genericAuthenticationMethodId(String genericAuthenticationMethodId) {
         if (this.genericAuthenticationMethodIds == null) {
            this.genericAuthenticationMethodIds = new ArrayList<>();
         }

         this.genericAuthenticationMethodIds.add(genericAuthenticationMethodId);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder genericAuthenticationMethodIds(Collection<? extends String> genericAuthenticationMethodIds) {
         if (genericAuthenticationMethodIds == null) {
            throw new NullPointerException("genericAuthenticationMethodIds cannot be null");
         }

         if (this.genericAuthenticationMethodIds == null) {
            this.genericAuthenticationMethodIds = new ArrayList<>();
         }

         this.genericAuthenticationMethodIds.addAll(genericAuthenticationMethodIds);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder clearGenericAuthenticationMethodIds() {
         if (this.genericAuthenticationMethodIds != null) {
            this.genericAuthenticationMethodIds.clear();
         }

         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder userManagementExtensionId(String userManagementExtensionId) {
         if (this.userManagementExtensionIds == null) {
            this.userManagementExtensionIds = new ArrayList<>();
         }

         this.userManagementExtensionIds.add(userManagementExtensionId);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder userManagementExtensionIds(Collection<? extends String> userManagementExtensionIds) {
         if (userManagementExtensionIds == null) {
            throw new NullPointerException("userManagementExtensionIds cannot be null");
         }

         if (this.userManagementExtensionIds == null) {
            this.userManagementExtensionIds = new ArrayList<>();
         }

         this.userManagementExtensionIds.addAll(userManagementExtensionIds);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder clearUserManagementExtensionIds() {
         if (this.userManagementExtensionIds != null) {
            this.userManagementExtensionIds.clear();
         }

         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder userLockedVisibility(UserLockedVisibility userLockedVisibility) {
         this.userLockedVisibility = userLockedVisibility;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder showAuthenticationMethodManagement(boolean showAuthenticationMethodManagement) {
         this.showAuthenticationMethodManagement = showAuthenticationMethodManagement;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder showTempLockingSection(boolean showTempLockingSection) {
         this.showTempLockingSection = showTempLockingSection;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder showAccountLinkTab(boolean showAccountLinkTab) {
         this.showAccountLinkTab = showAccountLinkTab;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder tokenSetting(String tokenSettingKey, Object tokenSettingValue) {
         if (this.tokenSettings$key == null) {
            this.tokenSettings$key = new ArrayList<>();
            this.tokenSettings$value = new ArrayList<>();
         }

         this.tokenSettings$key.add(tokenSettingKey);
         this.tokenSettings$value.add(tokenSettingValue);
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder tokenSettings(Map<? extends String, ? extends Object> tokenSettings) {
         if (tokenSettings == null) {
            throw new NullPointerException("tokenSettings cannot be null");
         }

         if (this.tokenSettings$key == null) {
            this.tokenSettings$key = new ArrayList<>();
            this.tokenSettings$value = new ArrayList<>();
         }

         for (Entry<? extends String, ? extends Object> $lombokEntry : tokenSettings.entrySet()) {
            this.tokenSettings$key.add($lombokEntry.getKey());
            this.tokenSettings$value.add($lombokEntry.getValue());
         }

         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder clearTokenSettings() {
         if (this.tokenSettings$key != null) {
            this.tokenSettings$key.clear();
            this.tokenSettings$value.clear();
         }

         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder hasUserTrailLogDatabaseConnection(boolean hasUserTrailLogDatabaseConnection) {
         this.hasUserTrailLogDatabaseConnection = hasUserTrailLogDatabaseConnection;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings.UserDetailSettingsBuilder deletionAllowed(boolean deletionAllowed) {
         this.deletionAllowed = deletionAllowed;
         return this;
      }

      @SuppressFBWarnings(justification = "generated code")
      public UserDetailSettings build() {
         List availableUserRoles = switch (this.availableUserRoles == null ? 0 : this.availableUserRoles.size()) {
            case 0 -> Collections.emptyList();
            case 1 -> Collections.singletonList(this.availableUserRoles.get(0));
            default -> Collections.unmodifiableList(new ArrayList<>(this.availableUserRoles));
         };

         List rowsOnUserDetailPage = switch (this.rowsOnUserDetailPage == null ? 0 : this.rowsOnUserDetailPage.size()) {
            case 0 -> Collections.emptyList();
            case 1 -> Collections.singletonList(this.rowsOnUserDetailPage.get(0));
            default -> Collections.unmodifiableList(new ArrayList<>(this.rowsOnUserDetailPage));
         };

         List lockReasons = switch (this.lockReasons == null ? 0 : this.lockReasons.size()) {
            case 0 -> Collections.emptyList();
            case 1 -> Collections.singletonList(this.lockReasons.get(0));
            default -> Collections.unmodifiableList(new ArrayList<>(this.lockReasons));
         };

         List overviewProfileItems = switch (this.overviewProfileItems == null ? 0 : this.overviewProfileItems.size()) {
            case 0 -> Collections.emptyList();
            case 1 -> Collections.singletonList(this.overviewProfileItems.get(0));
            default -> Collections.unmodifiableList(new ArrayList<>(this.overviewProfileItems));
         };

         List possibleNextAuthMethods = switch (this.possibleNextAuthMethods == null ? 0 : this.possibleNextAuthMethods.size()) {
            case 0 -> Collections.emptyList();
            case 1 -> Collections.singletonList(this.possibleNextAuthMethods.get(0));
            default -> Collections.unmodifiableList(new ArrayList<>(this.possibleNextAuthMethods));
         };

         List genericAuthenticationMethodIds = switch (this.genericAuthenticationMethodIds == null ? 0 : this.genericAuthenticationMethodIds.size()) {
            case 0 -> Collections.emptyList();
            case 1 -> Collections.singletonList(this.genericAuthenticationMethodIds.get(0));
            default -> Collections.unmodifiableList(new ArrayList<>(this.genericAuthenticationMethodIds));
         };

         List userManagementExtensionIds = switch (this.userManagementExtensionIds == null ? 0 : this.userManagementExtensionIds.size()) {
            case 0 -> Collections.emptyList();
            case 1 -> Collections.singletonList(this.userManagementExtensionIds.get(0));
            default -> Collections.unmodifiableList(new ArrayList<>(this.userManagementExtensionIds));
         };

         return new UserDetailSettings(
            this.editable,
            this.showUserValidSection,
            this.showRememberMeSection,
            this.allowsUsernameChange,
            this.generateUsername,
            this.usernameField,
            this.usernamePrefill,
            availableUserRoles,
            rowsOnUserDetailPage,
            lockReasons,
            this.showAuthMethodMigrationSection,
            overviewProfileItems,
            this.enableMultipleNextAuthMethods,
            this.authMethodNameToId,
            this.visibleAuthMethodIds,
            possibleNextAuthMethods,
            genericAuthenticationMethodIds,
            userManagementExtensionIds,
            this.userLockedVisibility,
            this.showAuthenticationMethodManagement,
            this.showTempLockingSection,
            this.showAccountLinkTab,
            switch (this.tokenSettings$key == null ? 0 : this.tokenSettings$key.size()) {
               case 0 -> Collections.emptyMap();
               case 1 -> Collections.singletonMap(this.tokenSettings$key.get(0), this.tokenSettings$value.get(0));
               default -> {
                  Map<String, Object> tokenSettings = new LinkedHashMap<>(
                     this.tokenSettings$key.size() < 1073741824
                        ? 1 + this.tokenSettings$key.size() + (this.tokenSettings$key.size() - 3) / 3
                        : Integer.MAX_VALUE
                  );

                  for (int $i = 0; $i < this.tokenSettings$key.size(); $i++) {
                     tokenSettings.put(this.tokenSettings$key.get($i), this.tokenSettings$value.get($i));
                  }

                  yield Collections.unmodifiableMap(tokenSettings);
               }
            },
            this.hasUserTrailLogDatabaseConnection,
            this.deletionAllowed
         );
      }

      @SuppressFBWarnings(justification = "generated code")
      @Override
      public String toString() {
         return "UserDetailSettings.UserDetailSettingsBuilder(editable="
            + this.editable
            + ", showUserValidSection="
            + this.showUserValidSection
            + ", showRememberMeSection="
            + this.showRememberMeSection
            + ", allowsUsernameChange="
            + this.allowsUsernameChange
            + ", generateUsername="
            + this.generateUsername
            + ", usernameField="
            + this.usernameField
            + ", usernamePrefill="
            + this.usernamePrefill
            + ", availableUserRoles="
            + this.availableUserRoles
            + ", rowsOnUserDetailPage="
            + this.rowsOnUserDetailPage
            + ", lockReasons="
            + this.lockReasons
            + ", showAuthMethodMigrationSection="
            + this.showAuthMethodMigrationSection
            + ", overviewProfileItems="
            + this.overviewProfileItems
            + ", enableMultipleNextAuthMethods="
            + this.enableMultipleNextAuthMethods
            + ", authMethodNameToId="
            + this.authMethodNameToId
            + ", visibleAuthMethodIds="
            + this.visibleAuthMethodIds
            + ", possibleNextAuthMethods="
            + this.possibleNextAuthMethods
            + ", genericAuthenticationMethodIds="
            + this.genericAuthenticationMethodIds
            + ", userManagementExtensionIds="
            + this.userManagementExtensionIds
            + ", userLockedVisibility="
            + this.userLockedVisibility
            + ", showAuthenticationMethodManagement="
            + this.showAuthenticationMethodManagement
            + ", showTempLockingSection="
            + this.showTempLockingSection
            + ", showAccountLinkTab="
            + this.showAccountLinkTab
            + ", tokenSettings$key="
            + this.tokenSettings$key
            + ", tokenSettings$value="
            + this.tokenSettings$value
            + ", hasUserTrailLogDatabaseConnection="
            + this.hasUserTrailLogDatabaseConnection
            + ", deletionAllowed="
            + this.deletionAllowed
            + ")";
      }
   }
}
