APIdia Launch Partner
Top Methods
jdk.internal.access

public Interface JavaNioAccess

Imports
jdk.internal.access.foreign.MappedMemoryUtilsProxy, .UnmapperProxy, jdk.internal.foreign.AbstractMemorySegmentImpl, .MemorySessionImpl, jdk.internal.misc.VM.BufferPool, java.lang.foreign.MemorySegment, java.nio.Buffer, .ByteBuffer

Method Summary

Modifier and TypeMethod and Description
public void
acquireSession(Buffer buffer)

Used by operations to make a buffer's session non-closeable (for the duration of the operation) by acquiring the session.

public MemorySegment
bufferSegment(Buffer buffer)

Used by jdk.internal.foreign.AbstractMemorySegmentImpl and byte buffer var handle views.

public long
getBufferAddress(Buffer buffer)

Used by jdk.internal.foreign.Utils.

public Object
getBufferBase(Buffer bb)

Used by jdk.internal.foreign.Utils.

public VM.BufferPool
getDirectBufferPool()

Used by jdk.internal.misc.VM.

public boolean
public AbstractMemorySegmentImpl
heapSegment(Buffer buffer, Object base, long offset, long length, boolean readOnly, MemorySessionImpl bufferScope)

public boolean
public MappedMemoryUtilsProxy
mappedMemoryUtils()

Used by jdk.internal.foreign.MappedMemorySegmentImpl.

public ByteBuffer
newDirectByteBuffer(long addr, int cap, Object obj, MemorySegment segment)

Constructs a direct ByteBuffer referring to the block of memory starting at the given memory address and extending cap bytes.

public ByteBuffer
newDirectByteBuffer(long addr, int cap)

Used by sun.nio.ch.Util.

public ByteBuffer
newHeapByteBuffer(byte[] hb, int offset, int capacity, MemorySegment segment)

Constructs an heap ByteBuffer with given backing array, offset, capacity and segment.

public ByteBuffer
newMappedByteBuffer(UnmapperProxy unmapperProxy, long addr, int cap, Object obj, MemorySegment segment)

Constructs a mapped ByteBuffer referring to the block of memory starting at the given memory address and extending cap bytes.

public int
pageSize()

Used by jdk.internal.foreign.NativeMemorySegmentImpl.

public void
public void
reserveMemory(long size, long cap)

Used by jdk.internal.foreign.NativeMemorySegmentImpl.

public int
public UnmapperProxy
unmapper(Buffer buffer)

Used by jdk.internal.foreign.Utils.

public void
unreserveMemory(long size, long cap)

Used by jdk.internal.foreign.NativeMemorySegmentImpl.

Method Detail

acquireSessionback to summary
public void acquireSession(Buffer buffer)

Used by operations to make a buffer's session non-closeable (for the duration of the operation) by acquiring the session.

acquireSession(buffer); try { performOperation(buffer); } finally { releaseSession(buffer); }
acquireSession(buffer);
try {
    performOperation(buffer);
} finally {
    releaseSession(buffer);
}
See Also
releaseSession(Buffer)
bufferSegmentback to summary
public MemorySegment bufferSegment(Buffer buffer)

Used by jdk.internal.foreign.AbstractMemorySegmentImpl and byte buffer var handle views.

getBufferAddressback to summary
public long getBufferAddress(Buffer buffer)

Used by jdk.internal.foreign.Utils.

getBufferBaseback to summary
public Object getBufferBase(Buffer bb)

Used by jdk.internal.foreign.Utils.

getDirectBufferPoolback to summary
public VM.BufferPool getDirectBufferPool()

Used by jdk.internal.misc.VM.

hasSessionback to summary
public boolean hasSession(Buffer buffer)
heapSegmentback to summary
public AbstractMemorySegmentImpl heapSegment(Buffer buffer, Object base, long offset, long length, boolean readOnly, MemorySessionImpl bufferScope)
isThreadConfinedback to summary
public boolean isThreadConfined(Buffer buffer)
mappedMemoryUtilsback to summary
public MappedMemoryUtilsProxy mappedMemoryUtils()

Used by jdk.internal.foreign.MappedMemorySegmentImpl.

newDirectByteBufferback to summary
public ByteBuffer newDirectByteBuffer(long addr, int cap, Object obj, MemorySegment segment)

Constructs a direct ByteBuffer referring to the block of memory starting at the given memory address and extending cap bytes. The ob parameter is an arbitrary object that is attached to the resulting buffer. Used by jdk.internal.foreignMemorySegmentImpl.

newDirectByteBufferback to summary
public ByteBuffer newDirectByteBuffer(long addr, int cap)

Used by sun.nio.ch.Util.

newHeapByteBufferback to summary
public ByteBuffer newHeapByteBuffer(byte[] hb, int offset, int capacity, MemorySegment segment)

Constructs an heap ByteBuffer with given backing array, offset, capacity and segment. Used by jdk.internal.foreignMemorySegmentImpl.

newMappedByteBufferback to summary
public ByteBuffer newMappedByteBuffer(UnmapperProxy unmapperProxy, long addr, int cap, Object obj, MemorySegment segment)

Constructs a mapped ByteBuffer referring to the block of memory starting at the given memory address and extending cap bytes. The ob parameter is an arbitrary object that is attached to the resulting buffer. The sync and fd parameters of the mapped buffer are derived from the UnmapperProxy. Used by jdk.internal.foreignMemorySegmentImpl.

pageSizeback to summary
public int pageSize()

Used by jdk.internal.foreign.NativeMemorySegmentImpl.

releaseSessionback to summary
public void releaseSession(Buffer buffer)
reserveMemoryback to summary
public void reserveMemory(long size, long cap)

Used by jdk.internal.foreign.NativeMemorySegmentImpl.

scaleShiftsback to summary
public int scaleShifts(Buffer buffer)
unmapperback to summary
public UnmapperProxy unmapper(Buffer buffer)

Used by jdk.internal.foreign.Utils.

unreserveMemoryback to summary
public void unreserveMemory(long size, long cap)

Used by jdk.internal.foreign.NativeMemorySegmentImpl.