void (@NotNull JavaCodeFragment codeFragment) { startElement(codeFragment); if (codeFragment instanceof PsiExpressionCodeFragment expressionCodeFragment) { PsiExpression expression = expressionCodeFragment.getExpression(); if (expression != null) { expression.accept(this); } } finishElement(codeFragment); }