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

@Singleton doesn't support getInstance() as documented

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.6
    • 1.6.1, 1.7-beta-1
    • ast builder
    • None

    Description

      e.g.

      @Singleton class MyService{
      }
      
      println MyService.instance // it works as expected
      println MyService.getInstance() //throw exception: No signature of method: static MyService.getInstance() is applicable for argument types: () values: []
      

      p.s. i found an old issue about Singleton in Groovy that probably could be closed GROOVY-1870

      Attachments

        1. 3442_v16x.txt
          2 kB
          Roshan Dawrani

        Activity

          People

            roshandawrani Roshan Dawrani
            mingfai Mingfai Ma
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: