Class SecureRandomProvider
- java.lang.Object
-
- com.inductiveautomation.ignition.common.util.SecureRandomProvider
-
public class SecureRandomProvider extends java.lang.Object
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description byte[]
generateSeed(int numBytes)
static SecureRandomProvider
get()
java.security.SecureRandom
getSecureRandom()
static void
initialize()
void
nextBytes(byte[] bytes)
int
nextInt()
int
nextInt(int n)
long
nextLong()
java.util.UUID
nextUUID()
Creates a new random UUID using the safely-generated SecureRandom
-
-
-
Method Detail
-
initialize
public static void initialize() throws java.security.NoSuchAlgorithmException
- Throws:
java.security.NoSuchAlgorithmException
-
get
public static SecureRandomProvider get()
-
getSecureRandom
public java.security.SecureRandom getSecureRandom()
-
generateSeed
public byte[] generateSeed(int numBytes)
-
nextBytes
public void nextBytes(byte[] bytes)
-
nextLong
public long nextLong()
-
nextInt
public int nextInt()
-
nextInt
public int nextInt(int n)
-
nextUUID
public java.util.UUID nextUUID()
Creates a new random UUID using the safely-generated SecureRandom
-
-