Gilles created RNG-53:
-------------------------
Summary: Prevent bad usage of internal class
Key: RNG-53
URL: https://issues.apache.org/jira/browse/RNG-53
Project: Commons RNG
Issue Type: Wish
Affects Versions: 1.0
Reporter: Gilles
Fix For: 1.1
There are two issues with class {{SamplerBase}} class (in package
{{o.a.c.rng.sampling.distribution}}):
# It allows inheritance.
# It introduces in the (protected) API methods that were meant for internal use
only.
By creating a subclass of {{SamplerBase}}, an application developer can access
more methods than the intended API (i.e. the {{sample()}} method).
A clean fix would involve a BC breaking of no consequence on bona fide users of
the API (as there is no reason to call the _protected_ methods from outside the
package were the samplers are defined).
[A discussion is taking place on the
ML|https://markmail.org/message/llarvlqcpstsoqgl].
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)