commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Phil Steitz (JIRA)" <>
Subject [jira] [Commented] (MATH-963) Interface "RandomGenerator" is missing "nextLong(long)" method
Date Thu, 04 Apr 2013 17:15:16 GMT


Phil Steitz commented on MATH-963:

The reason the method is missing from the interface is that it is not present in j.u.Random
and RandomGenerator is supposed to be a straight replacement for j.u.Random.  It might be
better to just add it to the abstract class, with a decent impl like what exists in the abstract
bitstream generator.  We should probably also replace the default impl of nextInt(int) with
something better if we can figure this out.  If we can find a good way to provide a good default
impl just based on nextBytes, then I guess I am +0 on adding this.  If not, I don't think
it is a good idea to force all RandomGenerators to implement something or inherit a not so
great default.
> Interface "RandomGenerator" is missing "nextLong(long)" method
> --------------------------------------------------------------
>                 Key: MATH-963
>                 URL:
>             Project: Commons Math
>          Issue Type: Bug
>    Affects Versions: 3.2
>            Reporter: Gilles
>            Priority: Trivial
>              Labels: api-change
> There is a method "nextInt(int)" but not "nextLong(long)".
> The "BitsStreamGenerator" class already implements it.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

View raw message