Uploaded image for project: 'Rules Repository'
  1. Rules Repository
  2. RSPEC-1118

Utility classes should not have public constructors

    XMLWordPrintable

    Details

    • Type: Code Smell Detection
    • Status: Active
    • Resolution: Unresolved
    • Labels:
    • Message:
      Hide
      Hide this public constructor.
      Add a private constructor to hide the implicit public one.
      Show
      Hide this public constructor. Add a private constructor to hide the implicit public one.
    • Default Severity:
      Major
    • Impact:
      Low
    • Likelihood:
      High
    • Default Quality Profiles:
      Sonar way
    • Covered Languages:
      C#, Java
    • Remediation Function:
      Constant/Issue
    • Constant Cost:
      5min
    • Analysis Scope:
      Main Sources, Test Sources
    • Checkstyle:
      HideUtilityClassConstructor
    • FxCop:
      StaticHolderTypesShouldBeSealed, CA1052, StaticHolderTypesShouldNotHaveConstructors, CA1053
    • PMD:
      UseUtilityClass, AtLeastOneConstructor
    • ReSharper:
      ConvertToStaticClass

      Attachments

        Issue Links

        1.
        C# RSPEC-3115 Language-Specification Active Unassigned
        2.
        Java RSPEC-4469 Language-Specification Active Unassigned

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            fabrice.bellingard Fabrice Bellingard
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated: