Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-7049

Groovysh: Completion should suggest field notation rather than bean accessors

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 2.4.0-beta-4
    • Groovysh
    • None

    Description

      currently for bean accessors, groovysh completion will rather suggest the accessors than the field type notation:
      groovy:000> class Foo

      {boolean foo}

      groovy:000> f = new Foo()
      groovy:000> f.<tab>
      getFoo() isFoo() setFoo(
      groovy:000> f.

      While this is a matter of programming taste, completion could aditionally offer foo in this case. This would also reduce visual clutter for classes with many such bean accessors.

      If the user has provided a prefix, such as:
      groovy:000> f.ge<tab>
      the getters should still appear

      Will try to make a PR so this can be tested inpractice.

      Attachments

        Activity

          People

            Unassigned Unassigned
            tkruse Thibault Kruse
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: