It should be obvious that this will NPE, but I've documented it for the others...
git-svn-id: https://samskivert.googlecode.com/svn/trunk@2919 6335cc39-0255-0410-8fd6-9bcaacd3b74c
This commit is contained in:
@@ -190,6 +190,7 @@ public class Randoms
|
||||
* <p><b>Implementation note:</b> a random number is generated for every entry with a
|
||||
* non-zero weight after the first such entry.
|
||||
*
|
||||
* @throws NullPointerException if the map is null.
|
||||
* @throws IllegalArgumentException if any weight is less than 0.
|
||||
*/
|
||||
public <T> T pick (Map<? extends T, ? extends Number> weightMap, T ifEmpty)
|
||||
|
||||
Reference in New Issue
Block a user