String (@NotNull final PsiComment comment) { final PsiFile psiFile = comment.getContainingFile(); final Language language = psiFile.getViewProvider().getBaseLanguage(); final Commenter commenter = LanguageCommenters.INSTANCE.forLanguage(language); if (commenter != null) { String text = comment.getText(); final String prefix = commenter.getBlockCommentPrefix(); if (prefix != null && text.startsWith(prefix)) { text = text.substring(prefix.length()); final String suffix = commenter.getBlockCommentSuffix(); if (suffix != null && text.length() > suffix.length()) { return text.substring(0, text.length() - suffix.length()).trim(); } } } return null; }