Search in sources :

Example 6 with ContentAssistEntry

use of org.eclipse.xtext.ide.editor.contentassist.ContentAssistEntry in project xtext-core by eclipse.

the class IdeContentProposalProvider method _createProposals.

protected void _createProposals(final Keyword keyword, final ContentAssistContext context, final IIdeContentProposalAcceptor acceptor) {
    boolean _filterKeyword = this.filterKeyword(keyword, context);
    if (_filterKeyword) {
        final ContentAssistEntry entry = this.proposalCreator.createProposal(keyword.getValue(), context);
        if ((entry != null)) {
            entry.setKind(ContentAssistEntry.KIND_KEYWORD);
            acceptor.accept(entry, this.proposalPriorities.getKeywordPriority(keyword.getValue(), entry));
        }
    }
}
Also used : ContentAssistEntry(org.eclipse.xtext.ide.editor.contentassist.ContentAssistEntry)

Aggregations

ContentAssistEntry (org.eclipse.xtext.ide.editor.contentassist.ContentAssistEntry)6 TextRegion (org.eclipse.xtext.util.TextRegion)2 ArrayList (java.util.ArrayList)1 List (java.util.List)1 CompletionItem (org.eclipse.lsp4j.CompletionItem)1 CompletionList (org.eclipse.lsp4j.CompletionList)1 Position (org.eclipse.lsp4j.Position)1 AbstractElement (org.eclipse.xtext.AbstractElement)1 AbstractRule (org.eclipse.xtext.AbstractRule)1 CrossReference (org.eclipse.xtext.CrossReference)1 RuleCall (org.eclipse.xtext.RuleCall)1 TerminalRule (org.eclipse.xtext.TerminalRule)1 IIdeContentProposalAcceptor (org.eclipse.xtext.ide.editor.contentassist.IIdeContentProposalAcceptor)1 IdeContentProposalAcceptor (org.eclipse.xtext.ide.editor.contentassist.IdeContentProposalAcceptor)1