Uploaded image for project: 'OpenMRS Core'
  1. OpenMRS Core
  2. TRUNK-5845 Search and fix minor errors and typos
  3. TRUNK-5935

Utility classes should not have public constructors

    XMLWordPrintable

Details

    • Sub-task
    • Status: Closed
    • Could
    • Resolution: Fixed
    • None
    • Core 2.5.0
    • None
    • Low

    Description

      Following the SonarQube:

      Utility classes, which are collections of static members, are not meant to be instantiated. Even abstract utility classes, which can be extended, should not have public constructors.

      First case:

      Second case:

      Solution:
      In all cases, add a private parameterless constructor.

      Gliffy Diagrams

        Attachments

          Activity

            People

              sacull Lukasz Debicki
              sacull Lukasz Debicki
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: