Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## Util.Random
Interface RandomNumberGenerator

All Known Implementing Classes:
  MersenneTwisterFast

    public interface RandomNumberGenerator

Interface for number generators

Method Summary
`boolean` | `nextBoolean()` Get the next boolean
`boolean` | `nextBoolean(double d)` Get the next boolean with probability of true defined by d 0<=d<=1
`char` | `nextChar()` Get the next char
`double` | `nextDouble()` Get the next double 0<=x<1
`int` | `nextInt()` Get the next int
`int` | `nextInt(int n)` Get the next int, where n is max
`short` | `nextShort()` Get the next short
`void` | `setSeed(int[] aI)` Set the seed
`void` | `setSeed(long l)` Set the seed

Method Detail

### nextInt

    int nextInt(int n)

  Get the next int, where n is max

  Parameters:
    `n` - max in value
  Returns:
    next random int

### nextInt

    int nextInt()

  Get the next int

  Returns:
    next int

### nextDouble

    double nextDouble()

  Get the next double 0<=x<1

  Returns:
    next double

### nextShort

    short nextShort()

  Get the next short

  Returns:
    next short

### nextChar

    char nextChar()

  Get the next char

  Returns:
    next char

### nextBoolean

    boolean nextBoolean()

  Get the next boolean

  Returns:
    next boolean

### nextBoolean

    boolean nextBoolean(double d)

  Get the next boolean with probability of true defined by d 0<=d<=1

  Parameters:
    `d` - probablity of true
  Returns:
    next boolean

### setSeed

    void setSeed(long l)

  Set the seed

  Parameters:
    `l` - seed

### setSeed

    void setSeed(int[] aI)

  Set the seed

  Parameters:
    `aI` - seed

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD