Avoid Constructors With Excessive Lines of Code Count

< 1 min read

Impact Area

Manageability

Severity

Medium

Affected Element

Apex Class

 

Rule ID #

SF-0012

Impact #

Excessive LoC Count on a constructor indicate that it is burdened with too many responsibilities.

Remediation #

Use a builder or factory pattern to create your objects.

Time to fix #

45 min

Updated on March 21, 2025
Was it helpful ?