ValidationInfo () { if (!myUseNestingRulesCheckBox.isSelected()) return null; List<CombinedNestingRule> items = myTable.getListTableModel().getItems(); for (int i = 0; i < items.size(); i++) { final CombinedNestingRule rule = items.get(i); final int row = i + 1; if (rule.parentSuffix.isEmpty()) { return new ValidationInfo(LangBundle.message("dialog.message.parent.file.suffix.must.be.empty.see.row", row), null); } if (rule.childSuffixes.isEmpty()) { return new ValidationInfo(LangBundle.message("dialog.message.child.file.suffix.must.be.empty.see.row", row), null); } for (String childSuffix : StringUtil.split(rule.childSuffixes, ";")) { if (rule.parentSuffix.equals(childSuffix.trim())) { return new ValidationInfo( LangBundle.message("dialog.message.parent.child.file.suffixes.must.be.equal.see.row", rule.parentSuffix, row), null); } } } return null; }