org.apache.ignite.internal.util

## Class GridRandom

- java.lang.Object
- - java.util.Random
  - - org.apache.ignite.internal.util.GridRandom

All Implemented Interfaces:
  Serializable

    public class GridRandom
    extends Random

Random to be used from a single thread. Compatible with `Random` but faster.

See Also:
  Serialized Form

### Constructor Summary

Constructors
Constructor and Description
`GridRandom()` Default constructor.
`GridRandom(long seed)`

### Method Summary

Methods
`protected int` `next(int bits)`
`void` `setSeed(long seed)`

### Methods inherited from class java.util.Random

`nextBoolean, nextBytes, nextDouble, nextFloat, nextGaussian, nextInt, nextInt, nextLong`

### Methods inherited from class java.lang.Object

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

### Constructor Detail

#### GridRandom

    public GridRandom()

Default constructor.

#### GridRandom

    public GridRandom(long seed)

Parameters:
  `seed` - Seed.

### Method Detail

#### setSeed

    public void setSeed(long seed)

Overrides:
  `setSeed` in class `Random`

#### next

    protected int next(int bits)

Overrides:
  `next` in class `Random`

2017 Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Fabric | : ver. 2.2.0
Release Date | : September 15 2017