PsiElementPredicate () { return new PsiElementPredicate() { @Override public boolean satisfiedBy(@NotNull PsiElement element) { if (!(element instanceof GrLiteral)) return false; String text = element.getText(); String quote = GrStringUtil.getStartQuote(text); return GrStringUtil.TRIPLE_QUOTES.equals(quote) || GrStringUtil.TRIPLE_DOUBLE_QUOTES.equals(quote); } }; }