September 2002
Intermediate to advanced
416 pages
14h 46m
English
JRandom
This class provides an implementation of the secure random generator. It is commonly used, as the initialization of secret keys requires a source of random numbers. Instances of this class are constructed directly.
public class JRandom extends java.util.Random { // Public Constructors public JRandom() throws jxta.security.exceptions.CryptoException; public JRandom(long lseed) throws jxta.security.exceptions.CryptoException; // Public Instance Methods public void generateData(byte[ ] buffer, int offset, int length); public void setSeed(byte[ ] buffer, int offset, int length); public String whoami(); // Public Methods Overriding Random public void nextBytes(byte[ ] buff); public int nextInt(); public long nextLong(); public void setSeed(long lseed); // synchronized // Protected Methods Overriding Random protected int next(int bits); // synchronized }
Read now
Unlock full access