String () { String text; try { text = getText(); } catch (PsiInvalidElementAccessException e) { text = e.getMessage(); } ModCommandAction modCommand = asModCommandAction(); Class<?> cls = modCommand == null ? getDelegate().getClass() : modCommand.getClass(); return "Intention: (" + cls.getName() + "): '" + text + "'"; }