Details
-
Improvement
-
Status: Closed
-
Minor
-
Resolution: Implemented
-
1.0
-
None
Description
All distribution currently use a public instance constructor.
Some implementations have different logic depending on the input arguments. This is currently handled by using method references to store the function implementation of e.g. the PMF for the distribution.
I suggest moving to private constructors with factory methods. These can create dedicated sub-class instances appropriate for the parameters.