| Modifier and Type | Class and Description |
|---|---|
| private static class | |
| private static class | |
| private static class | |
| private abstract static class |
| Modifier and Type | Field and Description |
|---|---|
| private final int | |
| private final Cleaner. | |
| private final boolean | |
| private final FileDescriptor | |
| private static final JavaIOFileDescriptorAccess | |
| private volatile FileLockTable | |
| private static boolean | |
| private static final int | |
| private static final int | |
| private static final int | |
| private static final int | |
| private static final long | |
| private static final long | |
| private static final FileDispatcher | |
| private final Closeable | |
| private final String | |
| private final Object | |
| private final boolean | |
| private final boolean | |
| private final NativeThreadSet | |
| private static final int | |
| private static volatile boolean | |
| private static volatile boolean | |
| private volatile boolean | |
| private final boolean |
| Access | Constructor and Description |
|---|---|
| private | FileChannelImpl(FileDescriptor fd, String path, boolean readable, boolean writable, boolean sync, boolean direct, Closeable parent)
|
| Modifier and Type | Method and Description |
|---|---|
| private void | |
| pack-priv int | available()
Returns an estimate of the number of remaining bytes that can be read from this channel without blocking. |
| private int | |
| private void | |
| private void | |
| private void | |
| private void | |
| private FileLockTable | |
| public void | force(boolean metaData)
Implements abstract java. Forces any updates to this channel's file to be written to the storage device that contains it. |
| public static VM. | getMappedBufferPool()
Invoked by sun.management.ManagementFactoryHelper to create the management interface for mapped buffers. |
| public static VM. | getSyncMappedBufferPool()
Invoked by sun.management.ManagementFactoryHelper to create the management interface for sync mapped buffers. |
| protected void | implCloseChannel()
Implements abstract java. Closes this channel. |
| private void | |
| private int | |
| private long | |
| private int | |
| private int | |
| private long | |
| private int | |
| pack-priv boolean | isOther()
Tells whether the channel represents something other than a regular file, directory, or symbolic link. |
| private boolean | |
| public FileLock | lock(long position, long size, boolean shared)
Implements abstract java. Acquires a lock on the given region of this channel's file. |
| public MappedByteBuffer | map(FileChannel.
Implements abstract java. Maps a region of this channel's file directly into memory. |
| public MemorySegment | map(FileChannel.
Overrides java. Maps a region of this channel's file into a new mapped memory segment, with the given offset, size and arena. |
| private FileChannelImpl. | |
| public static FileChannel | open(FileDescriptor fd, String path, boolean readable, boolean writable, boolean sync, boolean direct, Closeable parent)
|
| public long | position()
Implements abstract java. Implements java. Returns this channel's file position. |
| public FileChannel | position(long newPosition)
Implements abstract java. Implements java. Sets this channel's file position. |
| public int | read(ByteBuffer dst)
Implements abstract java. Implements java. Reads a sequence of bytes from this channel into the given buffer. |
| public long | read(ByteBuffer[] dsts, int offset, int length)
Implements abstract java. Implements java. Reads a sequence of bytes from this channel into a subsequence of the given buffers. |
| public int | read(ByteBuffer dst, long position)
Implements abstract java. Reads a sequence of bytes from this channel into the given buffer, starting at the given file position. |
| private int | |
| pack-priv void | |
| public void | |
| public long | size()
Implements abstract java. Implements java. Returns the current size of this channel's file. |
| private int | |
| private int | |
| private long | |
| private int | |
| private int | |
| private long | |
| private int | |
| private AsynchronousCloseException | transferFailed(ClosedChannelException cce, Channel other)
Invoked when ClosedChannelException is thrown during a transfer. |
| public long | transferFrom(ReadableByteChannel src, long position, long count)
Implements abstract java. Transfers bytes into this channel's file from the given readable byte channel. |
| private long | transferFromArbitraryChannel(ReadableByteChannel src, long position, long count)
Transfers bytes into this channel's file from the given channel. |
| private long | transferFromDirect(FileChannelImpl src, long position, long count)
Transfers bytes into this channel's file from the given channel's file. |
| private long | transferFromFileChannel(FileChannelImpl src, long position, long count)
Transfers bytes into this channel's file from the given channel's file. |
| private long | transferFromFileDescriptor(FileDescriptor srcFD, long position, long count)
Transfers bytes into this channel's file from the resource that the given file descriptor is connected to. |
| public long | transferTo(long position, long count, WritableByteChannel target)
Implements abstract java. Transfers bytes from this channel's file to the given writable byte channel. |
| private long | transferToArbitraryChannel(long position, long count, WritableByteChannel target)
Transfers bytes from channel's file to the given channel. |
| private long | Returns: the number of bytes transferred, UNSUPPORTED_CASE if this transfer cannot be done directly, or UNSUPPORTED if there is no direct supportTransfers bytes from this channel's file to the given channel's file or socket. |
| private long | transferToDirectInternal(long position, int count, WritableByteChannel target)
Transfers bytes from this channel's file from the given channel's file. |
| private long | transferToFileChannel(long position, int count, FileChannelImpl target)
Transfers bytes from this channel's file to the given channel's file. |
| private long | transferToFileDescriptor(long position, int count, FileDescriptor targetFD)
Transfers bytes from this channel's file to the resource that the given file descriptor is connected to. |
| private long | transferToSocketChannel(long position, int count, SocketChannelImpl target)
Transfers bytes from this channel's file to the given channel's socket. |
| private long | transferToTrustedChannel(long position, long count, WritableByteChannel target)
Transfers bytes from channel's file to the given channel. |
| public FileChannel | truncate(long newSize)
Implements abstract java. Implements java. Truncates this channel's file to the given size. |
| public FileLock | tryLock(long position, long size, boolean shared)
Implements abstract java. Attempts to acquire a lock on the given region of this channel's file. |
| private static void | |
| public int | write(ByteBuffer src)
Implements abstract java. Implements java. Writes a sequence of bytes to this channel from the given buffer. |
| public long | write(ByteBuffer[] srcs, int offset, int length)
Implements abstract java. Implements java. Writes a sequence of bytes to this channel from a subsequence of the given buffers. |
| public int | write(ByteBuffer src, long position)
Implements abstract java. Writes a sequence of bytes to this channel from the given buffer, starting at the given file position. |
| private int |