Alex Herbert created STATISTICS-41:
--------------------------------------

             Summary: Use factory constructors
                 Key: STATISTICS-41
                 URL: https://issues.apache.org/jira/browse/STATISTICS-41
             Project: Apache Commons Statistics
          Issue Type: Improvement
          Components: distribution
    Affects Versions: 1.0
            Reporter: Alex Herbert


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.

 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to