Package org.infinispan.container.offheap
Class MemoryAddressHash
- java.lang.Object
-
- org.infinispan.container.offheap.MemoryAddressHash
-
public class MemoryAddressHash extends Object
- Since:
- 9.0
- Author:
- wburns
-
-
Constructor Summary
Constructors Constructor Description MemoryAddressHash(int pointers, org.infinispan.container.offheap.OffsetCalculator offSetCalculator, OffHeapMemoryAllocator allocator)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddeallocate()longgetMemoryAddress(Object instance)longgetMemoryAddressOffset(int offset)longgetMemoryAddressOffsetNoTraceIfAbsent(int offset)voidputMemoryAddress(Object instance, long address)LongStreamtoStream()Returns a stream of longs that are all of the various memory locationsLongStreamtoStreamRemoved()Same astoStream()except that the memory addresses are also cleared out (set to 0)
-
-
-
Constructor Detail
-
MemoryAddressHash
public MemoryAddressHash(int pointers, org.infinispan.container.offheap.OffsetCalculator offSetCalculator, OffHeapMemoryAllocator allocator)
-
-
Method Detail
-
putMemoryAddress
public void putMemoryAddress(Object instance, long address)
-
getMemoryAddress
public long getMemoryAddress(Object instance)
-
getMemoryAddressOffset
public long getMemoryAddressOffset(int offset)
-
getMemoryAddressOffsetNoTraceIfAbsent
public long getMemoryAddressOffsetNoTraceIfAbsent(int offset)
-
deallocate
public void deallocate()
-
toStream
public LongStream toStream()
Returns a stream of longs that are all of the various memory locations- Returns:
- stream of the various memory locations
-
toStreamRemoved
public LongStream toStreamRemoved()
Same astoStream()except that the memory addresses are also cleared out (set to 0)- Returns:
- stream with the valid memory pointers to stored values
-
-