Object Dice

  • All Implemented Interfaces:

    
    public class Dice
    
                        

    Manage random things.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
      public final static Dice INSTANCE
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      final <T extends Any> T choose(List<T> list) Choose randomly an item in a list.
      final Integer index(Collection<?> col) Return a random index in a Collection.
      final Integer newInt(Integer max) Return a random int between 0 and max (excluded).
      final String newId() Return a new random Id.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait