void (PsiMethodCallExpression callExpression, PsiExpression qualifierExpression) { if (qualifierExpression instanceof PsiTypeCastExpression) { final PsiExpression element = ((PsiTypeCastExpression)qualifierExpression).getOperand(); if (element instanceof PsiMethodReferenceExpression) { final PsiLambdaExpression lambdaExpression = LambdaRefactoringUtil.convertMethodReferenceToLambda((PsiMethodReferenceExpression)element, false, true); if (lambdaExpression != null) { replaceWithLambdaBody(lambdaExpression); } } } }