PsiElement (PsiSwitchBlock switchBlock) { final PsiExpression expression = switchBlock.getExpression(); if (expression == null) { return null; } final PsiType type = expression.getType(); if (!(type instanceof PsiClassType)) { return null; } final PsiElement result = SwitchUtils.findDefaultElement(switchBlock); if (result == null) { return null; } final CompletenessResult completenessResult = PatternsInSwitchBlockHighlightingModel.evaluateSwitchCompleteness(switchBlock); return completenessResult == COMPLETE_WITHOUT_UNCONDITIONAL ? result : null; }