public abstract class SecureRandomSpi extends Object implements Serializable
SecureRandom类。
该类中的所有抽象方法必须由希望提供加密强伪随机数生成器的实现的每个服务提供者来实现。
SecureRandom , Serialized Form
| Constructor and Description |
|---|
SecureRandomSpi() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract byte[] |
engineGenerateSeed(int numBytes)
返回给定的种子字节数。
|
protected abstract void |
engineNextBytes(byte[] bytes)
生成用户指定的随机字节数。
|
protected abstract void |
engineSetSeed(byte[] seed)
重新设定这个随机对象。
|
protected abstract void engineSetSeed(byte[] seed)
seed - 种子。
protected abstract void engineNextBytes(byte[] bytes)
如果将呼叫engineSetSeed以前没有发生,给此方法的第一次调用这个强制SecureRandom实现自身的种子。 如果以前调用了engineSetSeed ,则不会发生此种子播放。
bytes - 要用随机字节填充的数组。
protected abstract byte[] engineGenerateSeed(int numBytes)
numBytes - 要生成的种子字节数。
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.