boolean ( PsiMethodCallExpression expression) { final PsiReferenceExpression methodExpression = expression.getMethodExpression(); final String methodName = methodExpression.getReferenceName(); if (!HardcodedMethodConstants.GET_CONNECTION.equals(methodName)) { return false; } final PsiMethod method = expression.resolveMethod(); if (method == null) { return false; } final PsiClass aClass = method.getContainingClass(); if (aClass == null) { return false; } final String className = aClass.getQualifiedName(); if (className == null) { return false; } return "java.sql.DriverManager".equals(className); }