use of com.intellij.ide.wizard.CommitStepException in project intellij-community by JetBrains.
the class BindToNewBeanStep method _commit.
public void _commit(boolean finishChosen) throws CommitStepException {
// Stop editing if any
final TableCellEditor cellEditor = myTable.getCellEditor();
if (cellEditor != null) {
cellEditor.stopCellEditing();
}
// Check that all included fields are bound to valid bean properties
final PsiNameHelper nameHelper = PsiNameHelper.getInstance(myData.myProject);
for (int i = 0; i < myData.myBindings.length; i++) {
final FormProperty2BeanProperty binding = myData.myBindings[i];
if (binding.myBeanProperty == null) {
continue;
}
if (!nameHelper.isIdentifier(binding.myBeanProperty.myName)) {
throw new CommitStepException(UIDesignerBundle.message("error.X.is.not.a.valid.property.name", binding.myBeanProperty.myName));
}
}
myData.myGenerateIsModified = myChkIsModified.isSelected();
}
Aggregations