@Override public void showParameterInfo(@NotNull GoArgumentList argList, @NotNull CreateParameterInfoContext context) { PsiElement parent = argList.getParent(); if (!(parent instanceof GoCallExpr)) return; GoFunctionType type = findFunctionType(((GoCallExpr)parent).getExpression().getGoType(null)); if (type != null) { context.setItemsToShow(new Object[]{type}); context.showHint(argList, argList.getTextRange().getStartOffset(), this); } }
@Override public void showParameterInfo(@NotNull CypherInvocation ci, @NotNull CreateParameterInfoContext context) { context.setItemsToShow(new Object[]{ci}); context.showHint(ci, ci.getTextRange().getStartOffset(), this); }
@Nullable @Override public PsiPerlCallArgumentsImpl findElementForParameterInfo(@NotNull CreateParameterInfoContext context) { // System.err.println("Find for create"); PsiPerlCallArgumentsImpl callArguments = findCallArguments(context); if (callArguments != null) { PerlParameterInfo[] methodParameterInfos = getMethodCallArguments(callArguments); if (methodParameterInfos == null || methodParameterInfos.length == 0) { return null; } markActiveParameters(callArguments, methodParameterInfos, context.getOffset()); context.setItemsToShow(methodParameterInfos); } return callArguments; }
@Override public void showParameterInfo(@NotNull MonkeyArguments monkeyArguments, @NotNull CreateParameterInfoContext context) { PsiElement parent = monkeyArguments.getParent(); PsiElement prevSibling = parent.getPrevSibling(); if (prevSibling instanceof MonkeyReferenceExpression) { MonkeyReferenceExpression referenceExpression = (MonkeyReferenceExpression) prevSibling; MonkeyFunctionDeclaration monkeyFunctionDeclaration = resolveCall(referenceExpression); if (monkeyFunctionDeclaration != null) { context.setItemsToShow(new Object[]{monkeyFunctionDeclaration}); context.showHint(monkeyArguments, monkeyArguments.getTextRange().getStartOffset(), this); } } }