Bug 429099

Summary: [templates] Add ${assist} to trigger code-assist from a template expansion
Product: [Eclipse Project] JDT Reporter: David Harkness <dharkness>
Component: TextAssignee: JDT-Text-Inbox <jdt-text-inbox>
Status: ASSIGNED --- QA Contact:
Severity: enhancement    
Priority: P3 CC: daniel_megert, noopur_gupta, srikanth_sankaran
Version: 4.2   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:

Description David Harkness CLA 2014-02-25 17:47:53 EST
Use case: I have a template that inserts an annotation that takes a single parameter chosen from a class's constants. I've omitted the part that adds the necessary imports.

    @SuppressFBWarnings(FindBugs.${cursor})

With this bound to "fb" you must enter this sequence:

    type `fb`
    type `ctrl-space`
    choose "fb template"
    type `ctrl-space` to trigger code-assist on "FindBugs."
    select constant

I would like the code-assist to trigger automatically and display the possible constants immediately.

Note: There's a placeholder that displays a popup selection list that looks like code-assist, but the values must be listed in the template itself. I want the values to be pulled from the FindBugs class.
Comment 1 Srikanth Sankaran CLA 2014-09-10 23:00:15 EDT
Pass to JDT/UI for comment. Does this belong in JDT/text instead ?