Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-6460

API - org.sonar.api.batch.rule.Checks#addAnnotatedChecks() is misleading

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.2
    • Component/s: Plugin API, Rules, Scanner
    • Labels:
      None

      Description

      The method addAnnotatedChecks() is defined twice:

      • addAnnotatedChecks(Object... checkClassesOrObjects)
      • addAnnotatedChecks(Collection checkClassesOrObjects)

      This method overloading is badly designed as using an Iterable does not have the expected behavior.

      The parameter with type Collection should be replaced by Iterable.

        Attachments

          Activity

            People

            Assignee:
            julien.henry Julien Henry
            Reporter:
            simon.brandhof Simon Brandhof (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Due:
              Created:
              Updated:
              Resolved: