Class Argon2BytesGenerator.FixedBlockPool
- java.lang.Object
-
- org.bouncycastle.crypto.generators.Argon2BytesGenerator.FixedBlockPool
-
- All Implemented Interfaces:
Argon2BytesGenerator.BlockPool
- Enclosing class:
- Argon2BytesGenerator
public static class Argon2BytesGenerator.FixedBlockPool extends java.lang.Object implements Argon2BytesGenerator.BlockPool
Bounded pool that recycles up tomaxBlocksArgon2BytesGenerator.Blockobjects. Excess blocks returned viadeallocate(Block)are dropped and left for the garbage collector. Returned blocks are zeroised both on deallocation and again on allocation, so a recycled block is never observed with stale data.
-
-
Constructor Summary
Constructors Constructor Description FixedBlockPool(int maxBlocks)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Argon2BytesGenerator.Blockallocate()voiddeallocate(Argon2BytesGenerator.Block block)
-
-
-
Method Detail
-
allocate
public Argon2BytesGenerator.Block allocate()
- Specified by:
allocatein interfaceArgon2BytesGenerator.BlockPool
-
deallocate
public void deallocate(Argon2BytesGenerator.Block block)
- Specified by:
deallocatein interfaceArgon2BytesGenerator.BlockPool
-
-