org.apache.xml.security.utils
Class PRNG

java.lang.Object
  |
  +--org.apache.xml.security.utils.PRNG

public class PRNG
extends java.lang.Object

Singleton for an application-wide SecureRandom.

Author:
$Author: geuerp $

Method Summary
static byte[] createBytes(int length)
           
static PRNG getInstance()
           
 java.security.SecureRandom getSecureRandom()
           
static void init(java.security.SecureRandom secureRandom)
           
 boolean nextBoolean()
           
 void nextBytes(byte[] bytes)
           
 double nextDouble()
           
 int nextInt()
           
 int nextInt(int i)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

init

public static void init(java.security.SecureRandom secureRandom)

getInstance

public static PRNG getInstance()

getSecureRandom

public java.security.SecureRandom getSecureRandom()

createBytes

public static byte[] createBytes(int length)

nextBytes

public void nextBytes(byte[] bytes)

nextDouble

public double nextDouble()

nextInt

public int nextInt()

nextInt

public int nextInt(int i)

nextBoolean

public boolean nextBoolean()