ReturnValue (PsiVariable outputParameter) { final PsiElement decl = myDeclarationCorrespondence.get(outputParameter); if (decl instanceof PsiVariable) { return new VariableReturnValue((PsiVariable)decl); } final List<PsiElement> parameterValue = getParameterValues(outputParameter); if (parameterValue != null && parameterValue.size() == 1 && parameterValue.get(0) instanceof PsiExpression) { return new ExpressionReturnValue((PsiExpression) parameterValue.get(0)); } else { return null; } }