public class MLKEMKeyFactory extends I2PThread implements KeyFactory
I2PThread.OOMEventListenerThread.State, Thread.UncaughtExceptionHandlerMAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY| Constructor and Description |
|---|
MLKEMKeyFactory(I2PAppContext ctx,
EncType type)Alice side only |
| Modifier and Type | Method and Description |
|---|---|
static MLKEMKeyFactory | getInstance()Returns the last created instance. |
KeyPair | getKeys()Pulls a prebuilt keypair from the queue,
or if not available, construct a new one. |
int | getMaxSize()Returns the current maximum precalc queue size. |
int | getMinSize()Returns the current minimum precalc queue size. |
int | getSize()Returns the current number of precalc keys queued. |
void | refreshPoolSize()Called by the Tuner every 30 seconds. |
void | returnUnused(KeyPair kp)Return an unused key pair
to be put back onto the queue for reuse. |
void | run()run. |
void | setMaxSize(int max)Sets the maximum precalc queue size. |
void | setMinSize(int min)Sets the minimum precalc queue size. |
void | shutdown()Note that this stops the singleton precalc thread. |
addOOMEventListener, fireOOM, removeOOMEventListener, startactiveCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, stop, stop, suspend, toString, yieldpublic MLKEMKeyFactory(I2PAppContext ctx, EncType type)
type - must be one of the internal types MLKEM*_INTpublic static MLKEMKeyFactory getInstance()
public KeyPair getKeys()
getKeys in interface KeyFactorypublic int getMaxSize()
public int getMinSize()
public int getSize()
public void refreshPoolSize()
public void returnUnused(KeyPair kp)
public void run()
I2PThreadpublic void setMaxSize(int max)
public void setMinSize(int min)
public void shutdown()