LocalQuickFix (Object... infos) { final PsiMethodCallExpression methodCallExpression = (PsiMethodCallExpression)infos[0]; final String methodName = methodCallExpression.getMethodExpression().getReferenceName(); final boolean put = HardcodedMethodConstants.PUT.equals(methodName); if (!(put || HardcodedMethodConstants.GET.equals(methodName))) { return null; } final PsiExpressionList argumentList = methodCallExpression.getArgumentList(); final PsiExpression[] arguments = argumentList.getExpressions(); for (PsiExpression argument : arguments) { final PsiType type = argument.getType(); if (type == null || !type.equalsToText(CommonClassNames.JAVA_LANG_STRING)) { return null; } } if (!put) { PsiType expectedType = ExpectedTypeUtils.findExpectedType(methodCallExpression, false, true); if (expectedType != null && !expectedType.equalsToText(CommonClassNames.JAVA_LANG_STRING)) { return null; } } return new UseOfPropertiesAsHashtableFix(put); }