boolean (@NotNull final ResourceBundle resourceBundle, @NotNull final PropertiesFile exceptedFile) { for (PropertiesFile file : resourceBundle.getPropertiesFiles()) { if (!(file instanceof PropertiesFileImpl)) { return true; } if (!file.equals(exceptedFile) && !file.isAlphaSorted()) { return false; } } return true; }