| Modifier and Type | Field and Description |
|---|---|
| pack-priv final long |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public long | address()
Implements java. Returns the address of this memory segment. |
| pack-priv NativeMemorySegmentImpl | dup(long offset, long size, boolean readOnly, MemorySessionImpl scope)
Implements abstract jdk.
|
| public Optional | heapBase()
Implements java. Returns the Java object stored in the on-heap region of memory backing this memory segment, if any. |
| public boolean | isNative()
Overrides jdk. Implements java. Returns |
| pack-priv ByteBuffer | |
| public long | |
| public final long | maxByteAlignment()
Implements java. Returns the maximum byte alignment associated with this memory segment. |
| public Object | |
| public long | unsafeGetOffset()
Implements abstract jdk.
|
| min | back to summary |
|---|---|
| pack-priv final long min | |
| NativeMemorySegmentImpl | back to summary |
|---|---|
pack-priv NativeMemorySegmentImpl(long min, long length, boolean readOnly, MemorySessionImpl scope)
| |
| address | back to summary |
|---|---|
| public long address() Implements java. Doc from java. Returns the address of this memory segment.
| |
| dup | back to summary |
|---|---|
| pack-priv NativeMemorySegmentImpl dup(long offset, long size, boolean readOnly, MemorySessionImpl scope) Implements abstract jdk.
| |
| heapBase | back to summary |
|---|---|
| public Optional Implements java. Doc from java. Returns the Java object stored in the on-heap region of memory backing this memory
segment, if any. For instance, if this memory segment is a heap segment created
with the
| |
| isNative | back to summary |
|---|---|
| public boolean isNative() Overrides jdk. Implements java. Doc from java. Returns
A native segment is created e.g. using the
| |
| makeByteBuffer | back to summary |
|---|---|
| pack-priv ByteBuffer makeByteBuffer() Implements abstract jdk.
| |
| maxAlignMask | back to summary |
|---|---|
| public long maxAlignMask() Implements abstract jdk.
| |
| maxByteAlignment | back to summary |
|---|---|
| public final long maxByteAlignment() Implements java. Doc from java. Returns the maximum byte alignment associated with this memory segment. The returned alignment is always a power of two and is derived from the segment address() and, if it is a heap segment, the type of the backing heap storage. This method can be used to ensure that a segment is sufficiently aligned with a layout: MemoryLayout layout = ... MemorySegment segment = ... if (segment.maxByteAlignment() < layout.byteAlignment()) { // Take action (e.g. throw an Exception) } | |
| unsafeGetBase | back to summary |
|---|---|
| public Object unsafeGetBase() Implements abstract jdk.
| |
| unsafeGetOffset | back to summary |
|---|---|
| public long unsafeGetOffset() Implements abstract jdk.
| |