Search in sources :

Example 16 with SignatureHelp

use of org.eclipse.lsp4j.SignatureHelp in project eclipse.jdt.ls by eclipse.

the class SignatureHelpHandlerTest method testSignatureHelp_lambda.

@Test
public void testSignatureHelp_lambda() throws JavaModelException {
    IJavaProject javaProject = JavaCore.create(project);
    IType type = javaProject.findType("test1.SignatureHelp");
    ICompilationUnit cu = type.getCompilationUnit();
    SignatureHelp help = getSignatureHelp(cu, 8, 14);
    assertNotNull(help);
    assertEquals(1, help.getSignatures().size());
    assertTrue(help.getSignatures().get(help.getActiveSignature()).getLabel().equals("test(Function<String,String> f) : void"));
}
Also used : ICompilationUnit(org.eclipse.jdt.core.ICompilationUnit) IJavaProject(org.eclipse.jdt.core.IJavaProject) SignatureHelp(org.eclipse.lsp4j.SignatureHelp) IType(org.eclipse.jdt.core.IType) Test(org.junit.Test)

Example 17 with SignatureHelp

use of org.eclipse.lsp4j.SignatureHelp in project vscode-nextgenas by BowlerHatLLC.

the class ActionScriptTextDocumentService method signatureHelp.

/**
     * Displays a function's parameters, including which one is currently
     * active. Called automatically by VSCode any time that the user types "(",
     * so be sure to check that a function call is actually happening at the
     * current position.
     */
@Override
public CompletableFuture<SignatureHelp> signatureHelp(TextDocumentPositionParams position) {
    String textDocumentUri = position.getTextDocument().getUri();
    if (!textDocumentUri.endsWith(AS_EXTENSION) && !textDocumentUri.endsWith(MXML_EXTENSION)) {
        //we couldn't find a node at the specified location
        return CompletableFuture.completedFuture(new SignatureHelp(Collections.emptyList(), -1, -1));
    }
    IASNode offsetNode = null;
    IMXMLTagData offsetTag = getOffsetMXMLTag(position);
    if (offsetTag != null) {
        IMXMLTagAttributeData attributeData = getMXMLTagAttributeWithValueAtOffset(offsetTag, currentOffset);
        if (attributeData != null) {
            //some attributes can have ActionScript completion, such as
            //events and properties with data binding
            IClassDefinition tagDefinition = (IClassDefinition) currentProject.resolveXMLNameToDefinition(offsetTag.getXMLName(), offsetTag.getMXMLDialect());
            IDefinition attributeDefinition = currentProject.resolveSpecifier(tagDefinition, attributeData.getShortName());
            if (attributeDefinition instanceof IEventDefinition) {
                IMXMLInstanceNode mxmlNode = (IMXMLInstanceNode) getOffsetNode(position);
                IMXMLEventSpecifierNode eventNode = mxmlNode.getEventSpecifierNode(attributeData.getShortName());
                for (IASNode asNode : eventNode.getASNodes()) {
                    IASNode containingNode = getContainingNodeIncludingStart(asNode, currentOffset);
                    if (containingNode != null) {
                        offsetNode = containingNode;
                    }
                }
                if (offsetNode == null) {
                    offsetNode = eventNode;
                }
            }
        }
    }
    if (offsetNode == null) {
        offsetNode = getOffsetNode(position);
    }
    if (offsetNode == null) {
        //we couldn't find a node at the specified location
        return CompletableFuture.completedFuture(new SignatureHelp(Collections.emptyList(), -1, -1));
    }
    IFunctionCallNode functionCallNode = getAncestorFunctionCallNode(offsetNode);
    IFunctionDefinition functionDefinition = null;
    if (functionCallNode != null) {
        IExpressionNode nameNode = functionCallNode.getNameNode();
        IDefinition definition = nameNode.resolve(currentUnit.getProject());
        if (definition instanceof IFunctionDefinition) {
            functionDefinition = (IFunctionDefinition) definition;
        } else if (definition instanceof IClassDefinition) {
            IClassDefinition classDefinition = (IClassDefinition) definition;
            functionDefinition = classDefinition.getConstructor();
        } else if (nameNode instanceof IIdentifierNode) {
            //special case for super()
            IIdentifierNode identifierNode = (IIdentifierNode) nameNode;
            if (identifierNode.getName().equals(IASKeywordConstants.SUPER)) {
                ITypeDefinition typeDefinition = nameNode.resolveType(currentProject);
                if (typeDefinition instanceof IClassDefinition) {
                    IClassDefinition classDefinition = (IClassDefinition) typeDefinition;
                    functionDefinition = classDefinitionToConstructor(classDefinition);
                }
            }
        }
    }
    if (functionDefinition != null) {
        SignatureHelp result = new SignatureHelp();
        List<SignatureInformation> signatures = new ArrayList<>();
        SignatureInformation signatureInfo = new SignatureInformation();
        signatureInfo.setLabel(getSignatureLabel(functionDefinition));
        List<ParameterInformation> parameters = new ArrayList<>();
        for (IParameterDefinition param : functionDefinition.getParameters()) {
            ParameterInformation paramInfo = new ParameterInformation();
            paramInfo.setLabel(param.getBaseName());
            parameters.add(paramInfo);
        }
        signatureInfo.setParameters(parameters);
        signatures.add(signatureInfo);
        result.setSignatures(signatures);
        result.setActiveSignature(0);
        int index = getFunctionCallNodeArgumentIndex(functionCallNode, offsetNode);
        IParameterDefinition[] params = functionDefinition.getParameters();
        int paramCount = params.length;
        if (paramCount > 0 && index >= paramCount) {
            if (index >= paramCount) {
                IParameterDefinition lastParam = params[paramCount - 1];
                if (lastParam.isRest()) {
                    //functions with rest parameters may accept any
                    //number of arguments, so continue to make the rest
                    //parameter active
                    index = paramCount - 1;
                } else {
                    //if there's no rest parameter, and we're beyond the
                    //final parameter, none should be active
                    index = -1;
                }
            }
        }
        if (index != -1) {
            result.setActiveParameter(index);
        }
        return CompletableFuture.completedFuture(result);
    }
    return CompletableFuture.completedFuture(new SignatureHelp(Collections.emptyList(), -1, -1));
}
Also used : IMXMLEventSpecifierNode(org.apache.flex.compiler.tree.mxml.IMXMLEventSpecifierNode) IClassDefinition(org.apache.flex.compiler.definitions.IClassDefinition) IMXMLInstanceNode(org.apache.flex.compiler.tree.mxml.IMXMLInstanceNode) ITypeDefinition(org.apache.flex.compiler.definitions.ITypeDefinition) ArrayList(java.util.ArrayList) IIdentifierNode(org.apache.flex.compiler.tree.as.IIdentifierNode) SignatureHelp(org.eclipse.lsp4j.SignatureHelp) IMXMLTagData(org.apache.flex.compiler.mxml.IMXMLTagData) IFunctionCallNode(org.apache.flex.compiler.tree.as.IFunctionCallNode) ParameterInformation(org.eclipse.lsp4j.ParameterInformation) IDefinition(org.apache.flex.compiler.definitions.IDefinition) IFunctionDefinition(org.apache.flex.compiler.definitions.IFunctionDefinition) SignatureInformation(org.eclipse.lsp4j.SignatureInformation) IASNode(org.apache.flex.compiler.tree.as.IASNode) IParameterDefinition(org.apache.flex.compiler.definitions.IParameterDefinition) IEventDefinition(org.apache.flex.compiler.definitions.IEventDefinition) IExpressionNode(org.apache.flex.compiler.tree.as.IExpressionNode) IMXMLTagAttributeData(org.apache.flex.compiler.mxml.IMXMLTagAttributeData)

Example 18 with SignatureHelp

use of org.eclipse.lsp4j.SignatureHelp in project eclipse.jdt.ls by eclipse.

the class SignatureHelpHandler method signatureHelp.

public SignatureHelp signatureHelp(TextDocumentPositionParams position, IProgressMonitor monitor) {
    SignatureHelp help = new SignatureHelp();
    if (!preferenceManager.getPreferences(null).isSignatureHelpEnabled()) {
        return help;
    }
    try {
        ICompilationUnit unit = JDTUtils.resolveCompilationUnit(position.getTextDocument().getUri());
        final int offset = JsonRpcHelpers.toOffset(unit.getBuffer(), position.getPosition().getLine(), position.getPosition().getCharacter());
        int[] contextInfomation = getContextInfomation(unit.getBuffer(), offset);
        if (contextInfomation[0] == -1) {
            return help;
        }
        SignatureHelpRequestor collector = new SignatureHelpRequestor(unit, contextInfomation[0] + 1);
        if (offset > -1 && !monitor.isCanceled()) {
            unit.codeComplete(contextInfomation[0] + 1, collector, monitor);
            help = collector.getSignatureHelp(monitor);
            if (help != null) {
                int currentParameter = contextInfomation[1];
                List<SignatureInformation> infos = help.getSignatures();
                for (int i = 0; i < infos.size(); i++) {
                    if (infos.get(i).getParameters().size() >= currentParameter + 1) {
                        help.setActiveSignature(i);
                        help.setActiveParameter(currentParameter);
                        break;
                    }
                }
            }
        }
    } catch (CoreException ex) {
        JavaLanguageServerPlugin.logException("Find signatureHelp failure ", ex);
    }
    return help;
}
Also used : ICompilationUnit(org.eclipse.jdt.core.ICompilationUnit) SignatureInformation(org.eclipse.lsp4j.SignatureInformation) CoreException(org.eclipse.core.runtime.CoreException) SignatureHelp(org.eclipse.lsp4j.SignatureHelp) SignatureHelpRequestor(org.eclipse.jdt.ls.core.internal.contentassist.SignatureHelpRequestor)

Example 19 with SignatureHelp

use of org.eclipse.lsp4j.SignatureHelp in project xtext-core by eclipse.

the class SignatureHelpServiceImpl method getSignatureHelp.

private SignatureHelp getSignatureHelp(OperationCall call, String operationName, int offset) {
    // If the offset exceeds either the opening or the closing characters'
    // offset we should not
    // provide signature help at all.
    List<Integer> separatorIndices = new ArrayList<>();
    for (INode node : NodeModelUtils.getNode(call).getChildren()) {
        String text = node.getText();
        if (SignatureHelpServiceImpl.OPENING_CHAR.equals(text) && node.getOffset() >= offset) {
            return ISignatureHelpService.EMPTY;
        } else {
            if (SignatureHelpServiceImpl.CLOSING_CHAR.equals(text) && node.getOffset() < offset) {
                return ISignatureHelpService.EMPTY;
            } else {
                if (SignatureHelpServiceImpl.SEPARATOR_CHAR.equals(text)) {
                    separatorIndices.add(node.getOffset());
                }
            }
        }
    }
    // Here we will distinguish between three different AST states:
    // 1. Valid state: when the number of parameter separators equals with
    // the number of (parameters - 1)
    // and each separator is surrounded by two parameters.
    // 2. Broken recoverable state: the number of parameters equals with the
    // number of separators and the
    // last separator offset is greater than the last parameter (offset +
    // length) and each separator is
    // surrounded by two parameters. Expect the last separator.
    // 3. Broken inconsistent state: non of the above cases.
    int paramCount = call.getParams().size();
    int separatorCount = separatorIndices.size();
    if (separatorCount + 1 == paramCount || separatorCount == paramCount) {
        List<INode> paramNodes = NodeModelUtils.findNodesForFeature(call, TestLanguagePackage.Literals.OPERATION__PARAMS);
        // Parameter count could be greater than separator count.
        for (int i = 0; i < separatorCount; i++) {
            INode paramNode = paramNodes.get(i);
            // should not be provided.
            if (paramNode.getOffset() + paramNode.getLength() > separatorIndices.get(i).intValue()) {
                return ISignatureHelpService.EMPTY;
            }
        }
    } else {
        return ISignatureHelpService.EMPTY;
    }
    final int currentParameter;
    if (paramCount != 0) {
        if (separatorIndices.contains(offset)) {
            currentParameter = separatorIndices.indexOf(offset) + 2;
        } else {
            // Here we can execute a binary search for sure, because the
            // nodes where visited in order.
            currentParameter = -Collections.binarySearch(separatorIndices, offset);
        }
    } else {
        currentParameter = 0;
    }
    Iterable<Operation> visibleOperations = Iterables.filter(getVisibleOperationsWithName(call, operationName), it -> currentParameter <= it.getParams().size());
    int paramOffset = separatorIndices.contains(offset) ? 2 : 1;
    final Integer activeParamIndex;
    if (paramCount == 0) {
        Iterable<Integer> paramSize = Iterables.transform(visibleOperations, it -> it.getParams().size());
        // parameter on use-side.
        if (!Iterables.any(paramSize, it -> it.intValue() == 0) && Iterables.any(visibleOperations, it -> !it.getParams().isEmpty())) {
            activeParamIndex = 0;
        } else {
            activeParamIndex = null;
        }
    } else {
        activeParamIndex = currentParameter - paramOffset;
    }
    SignatureHelp signatureHelp = new SignatureHelp();
    signatureHelp.setActiveParameter(activeParamIndex);
    signatureHelp.setActiveSignature(0);
    signatureHelp.setSignatures(IterableExtensions.sortWith(IterableExtensions.toList(Iterables.transform(visibleOperations, (Operation operation) -> {
        SignatureInformation signatureInformation = new SignatureInformation(getLabel(operation));
        signatureInformation.setParameters(Lists.transform(operation.getParams(), (Parameter param) -> new ParameterInformation(param.getName() + ": " + getLabel(param.getType()))));
        return signatureInformation;
    })), SignatureHelpServiceImpl.SIGNATURE_INFO_ORDERING));
    return signatureHelp;
}
Also used : TestLanguagePackage(org.eclipse.xtext.ide.tests.testlanguage.testLanguage.TestLanguagePackage) Operation(org.eclipse.xtext.ide.tests.testlanguage.testLanguage.Operation) Arrays(java.util.Arrays) Iterables(com.google.common.collect.Iterables) TypeReference(org.eclipse.xtext.ide.tests.testlanguage.testLanguage.TypeReference) Inject(com.google.inject.Inject) NodeModelUtils(org.eclipse.xtext.nodemodel.util.NodeModelUtils) ArrayList(java.util.ArrayList) Strings(com.google.common.base.Strings) Document(org.eclipse.xtext.ide.server.Document) Lists(com.google.common.collect.Lists) EcoreUtil2(org.eclipse.xtext.EcoreUtil2) CancelIndicator(org.eclipse.xtext.util.CancelIndicator) INode(org.eclipse.xtext.nodemodel.INode) Objects(com.google.common.base.Objects) Parameter(org.eclipse.xtext.ide.tests.testlanguage.testLanguage.Parameter) XtextResource(org.eclipse.xtext.resource.XtextResource) PrimitiveType(org.eclipse.xtext.ide.tests.testlanguage.testLanguage.PrimitiveType) ParameterInformation(org.eclipse.lsp4j.ParameterInformation) ISignatureHelpService(org.eclipse.xtext.ide.server.signatureHelp.ISignatureHelpService) EObject(org.eclipse.emf.ecore.EObject) SignatureInformation(org.eclipse.lsp4j.SignatureInformation) EObjectAtOffsetHelper(org.eclipse.xtext.resource.EObjectAtOffsetHelper) SignatureHelp(org.eclipse.lsp4j.SignatureHelp) List(java.util.List) IterableExtensions(org.eclipse.xtext.xbase.lib.IterableExtensions) OperationCall(org.eclipse.xtext.ide.tests.testlanguage.testLanguage.OperationCall) IScopeProvider(org.eclipse.xtext.scoping.IScopeProvider) TypeDeclaration(org.eclipse.xtext.ide.tests.testlanguage.testLanguage.TypeDeclaration) Preconditions(com.google.common.base.Preconditions) SignatureHelpParams(org.eclipse.lsp4j.SignatureHelpParams) Comparator(java.util.Comparator) Collections(java.util.Collections) IEObjectDescription(org.eclipse.xtext.resource.IEObjectDescription) Joiner(com.google.common.base.Joiner) INode(org.eclipse.xtext.nodemodel.INode) ArrayList(java.util.ArrayList) SignatureHelp(org.eclipse.lsp4j.SignatureHelp) Operation(org.eclipse.xtext.ide.tests.testlanguage.testLanguage.Operation) ParameterInformation(org.eclipse.lsp4j.ParameterInformation) SignatureInformation(org.eclipse.lsp4j.SignatureInformation) Parameter(org.eclipse.xtext.ide.tests.testlanguage.testLanguage.Parameter)

Example 20 with SignatureHelp

use of org.eclipse.lsp4j.SignatureHelp in project eclipse.jdt.ls by eclipse.

the class SignatureHelpHandler method signatureHelp.

public SignatureHelp signatureHelp(SignatureHelpParams position, IProgressMonitor monitor) {
    SignatureHelp help = new SignatureHelp();
    if (!preferenceManager.getPreferences(null).isSignatureHelpEnabled()) {
        return help;
    }
    try {
        ICompilationUnit unit = JDTUtils.resolveCompilationUnit(position.getTextDocument().getUri());
        final int offset = JsonRpcHelpers.toOffset(unit.getBuffer(), position.getPosition().getLine(), position.getPosition().getCharacter());
        int[] contextInfomation = getContextInfomation(unit.getBuffer(), offset);
        ASTNode node = getNode(unit, contextInfomation, monitor);
        if (node == null) {
            return help;
        }
        IMethod method = getMethod(node);
        String name = method != null ? method.getElementName() : getMethodName(node, unit, contextInfomation);
        SignatureHelpRequestor collector = new SignatureHelpRequestor(unit, name, contextInfomation[0] + 1);
        if (offset > -1 && !monitor.isCanceled()) {
            unit.codeComplete(contextInfomation[0] + 1, collector, monitor);
            help = collector.getSignatureHelp(monitor);
            if (help.getSignatures().isEmpty()) {
                int pos = offset;
                if (method != null) {
                    int start;
                    if (node instanceof MethodInvocation) {
                        start = ((MethodInvocation) node).getName().getStartPosition();
                    } else if (node instanceof ClassInstanceCreation) {
                        start = ((ClassInstanceCreation) node).getType().getStartPosition();
                    } else {
                        start = node.getStartPosition();
                    }
                    pos = start + method.getElementName().length();
                }
                unit.codeComplete(pos, collector, monitor);
                help = collector.getSignatureHelp(monitor);
                addConstructorProposals(help, node, method, collector, pos);
            }
            if (!monitor.isCanceled() && help != null) {
                SignatureHelp help2 = null;
                SignatureHelpRequestor collector2 = null;
                if (contextInfomation[0] + 1 != offset) {
                    collector2 = new SignatureHelpRequestor(unit, offset, name, true);
                    unit.codeComplete(offset, collector2, monitor);
                    help2 = collector2.getSignatureHelp(monitor);
                }
                int currentParameter = contextInfomation[1];
                int size = currentParameter + 1;
                List<SignatureInformation> infos = help.getSignatures();
                int activeParameter = currentParameter < 0 ? 0 : currentParameter;
                if (node != null) {
                    IJavaProject javaProject = unit.getJavaProject();
                    if (help2 != null) {
                        if (method != null) {
                            for (int i = 0; i < infos.size(); i++) {
                                if (infos.get(i).getParameters().size() >= size) {
                                    CompletionProposal proposal = collector.getInfoProposals().get(infos.get(i));
                                    IMethod m = JDTUtils.resolveMethod(proposal, javaProject, monitor);
                                    if (!monitor.isCanceled() && JDTUtils.isSameParameters(m, method)) {
                                        help.setActiveSignature(i);
                                        help.setActiveParameter(activeParameter);
                                        return help;
                                    }
                                }
                            }
                        }
                        if (!monitor.isCanceled() && help.getActiveSignature() == null) {
                            for (int i = 0; i < infos.size(); i++) {
                                if (infos.get(i).getParameters().size() >= size) {
                                    CompletionProposal proposal = collector.getInfoProposals().get(infos.get(i));
                                    IMethod m = JDTUtils.resolveMethod(proposal, javaProject, monitor);
                                    if (!monitor.isCanceled() && isSameParameters(m, help2, collector2, javaProject, monitor)) {
                                        help.setActiveSignature(i);
                                        help.setActiveParameter(activeParameter);
                                        return help;
                                    }
                                    for (CompletionProposal typeProposal : collector2.getTypeProposals()) {
                                        if (isSameParameters(m, method, typeProposal)) {
                                            help.setActiveSignature(i);
                                            help.setActiveParameter(activeParameter);
                                            return help;
                                        }
                                    }
                                }
                            }
                        }
                    }
                    if (!monitor.isCanceled() && help.getActiveSignature() == null) {
                        if (method != null) {
                            for (int i = 0; i < infos.size(); i++) {
                                if (infos.get(i).getParameters().size() >= size) {
                                    CompletionProposal proposal = collector.getInfoProposals().get(infos.get(i));
                                    IMethod m = JDTUtils.resolveMethod(proposal, javaProject, monitor);
                                    if (!monitor.isCanceled() && JDTUtils.isSameParameters(method, m)) {
                                        help.setActiveSignature(i);
                                        help.setActiveParameter(activeParameter);
                                        return help;
                                    }
                                }
                            }
                        }
                    }
                    if (!monitor.isCanceled() && help.getActiveSignature() == null) {
                        for (int i = 0; i < infos.size(); i++) {
                            CompletionProposal proposal = collector.getInfoProposals().get(infos.get(i));
                            if (Flags.isVarargs(proposal.getFlags())) {
                                help.setActiveSignature(i);
                                char[][] infoTypes = Signature.getParameterTypes(SignatureUtil.fix83600(proposal.getSignature()));
                                if (infoTypes.length <= activeParameter) {
                                    help.setActiveParameter(infoTypes.length - 1);
                                } else {
                                    help.setActiveParameter(activeParameter);
                                }
                                return help;
                            }
                        }
                    }
                    if (!monitor.isCanceled() && help.getActiveSignature() == null && node instanceof Block) {
                        String methodName = getMethodName(node, unit, contextInfomation);
                        for (int i = 0; i < infos.size(); i++) {
                            if (infos.get(i).getParameters().size() >= activeParameter) {
                                CompletionProposal proposal = collector.getInfoProposals().get(infos.get(i));
                                IMethod m = JDTUtils.resolveMethod(proposal, javaProject, monitor);
                                if (!monitor.isCanceled() && m != null && m.getElementName().equals(methodName)) {
                                    help.setActiveSignature(i);
                                    help.setActiveParameter(activeParameter);
                                    return help;
                                }
                            }
                        }
                    }
                    if (method != null && !monitor.isCanceled() && help.getActiveSignature() == null) {
                        for (int i = 0; i < infos.size(); i++) {
                            if (infos.get(i).getParameters().size() >= size) {
                                CompletionProposal proposal = collector.getInfoProposals().get(infos.get(i));
                                IMethod m = JDTUtils.resolveMethod(proposal, javaProject, monitor);
                                if (!monitor.isCanceled() && isSameParameters(m, method, null)) {
                                    help.setActiveSignature(i);
                                    help.setActiveParameter(activeParameter);
                                    return help;
                                }
                            }
                        }
                    }
                }
            }
        }
    } catch (CoreException ex) {
        JavaLanguageServerPlugin.logException("Find signatureHelp failure ", ex);
    }
    return help;
}
Also used : ClassInstanceCreation(org.eclipse.jdt.core.dom.ClassInstanceCreation) ICompilationUnit(org.eclipse.jdt.core.ICompilationUnit) InternalCompletionProposal(org.eclipse.jdt.internal.codeassist.InternalCompletionProposal) CompletionProposal(org.eclipse.jdt.core.CompletionProposal) SignatureHelp(org.eclipse.lsp4j.SignatureHelp) MethodInvocation(org.eclipse.jdt.core.dom.MethodInvocation) SignatureInformation(org.eclipse.lsp4j.SignatureInformation) IJavaProject(org.eclipse.jdt.core.IJavaProject) CoreException(org.eclipse.core.runtime.CoreException) ASTNode(org.eclipse.jdt.core.dom.ASTNode) Block(org.eclipse.jdt.core.dom.Block) IMethod(org.eclipse.jdt.core.IMethod) SignatureHelpRequestor(org.eclipse.jdt.ls.core.internal.contentassist.SignatureHelpRequestor)

Aggregations

SignatureHelp (org.eclipse.lsp4j.SignatureHelp)31 ICompilationUnit (org.eclipse.jdt.core.ICompilationUnit)23 Test (org.junit.Test)21 IPackageFragment (org.eclipse.jdt.core.IPackageFragment)17 SignatureInformation (org.eclipse.lsp4j.SignatureInformation)7 IJavaProject (org.eclipse.jdt.core.IJavaProject)5 IType (org.eclipse.jdt.core.IType)4 ArrayList (java.util.ArrayList)3 CoreException (org.eclipse.core.runtime.CoreException)2 CompletionProposal (org.eclipse.jdt.core.CompletionProposal)2 InternalCompletionProposal (org.eclipse.jdt.internal.codeassist.InternalCompletionProposal)2 SignatureHelpRequestor (org.eclipse.jdt.ls.core.internal.contentassist.SignatureHelpRequestor)2 ParameterInformation (org.eclipse.lsp4j.ParameterInformation)2 Joiner (com.google.common.base.Joiner)1 Objects (com.google.common.base.Objects)1 Preconditions (com.google.common.base.Preconditions)1 Strings (com.google.common.base.Strings)1 Iterables (com.google.common.collect.Iterables)1 Lists (com.google.common.collect.Lists)1 Inject (com.google.inject.Inject)1