Uploaded image for project: 'Google Code-in'
  1. Google Code-in
  2. GCI-173

Add a private constructor to ErrorMessageConstants

    XMLWordPrintable

Details

    • Low

    Description

      Add the private constructor below, to https://github.com/openmrs/openmrs-core/blob/master/web/src/main/java/org/openmrs/web/filter/util/ErrorMessageConstants.java

      private ErrorMessageConstants() {
      }
      

      Background information:

      Utility classes should not have public constructors
      Utility classes, which are a collection of static members, are not meant to be instantiated. Even abstract utility classes, which can be extended, should not have public constructors.
      Java adds an implicit public constructor to every class which does not define at least one explicitly. Hence, at least one non-public constructor should be defined.
      

      Gliffy Diagrams

        Attachments

          Activity

            People

              cintiadr Cintia Del Rio
              dkayiwa Daniel Kayiwa
              Daniil Durnev Daniil Durnev
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - 1 week Original Estimate - 1 week
                  1w
                  Remaining:
                  Remaining Estimate - 1 week
                  1w
                  Logged:
                  Remaining Estimate - 1 week
                  10m