public abstract class FileBaseDefault extends FileBase
FileChannel.MapMode| 构造器和说明 |
|---|
FileBaseDefault() |
| 限定符和类型 | 方法和说明 |
|---|---|
protected abstract void |
implTruncate(long size)
The truncate implementation.
|
long |
position() |
FileChannel |
position(long newPosition) |
int |
read(ByteBuffer dst) |
FileChannel |
truncate(long newLength) |
int |
write(ByteBuffer src) |
force, implCloseChannel, lock, map, read, read, transferFrom, transferTo, tryLock, write, writebegin, close, end, isOpenpublic final long position()
throws IOException
position 在接口中 SeekableByteChannelposition 在类中 FileChannelIOExceptionpublic final FileChannel position(long newPosition) throws IOException
position 在接口中 SeekableByteChannelposition 在类中 FileChannelIOExceptionpublic final int read(ByteBuffer dst) throws IOException
read 在接口中 ReadableByteChannelread 在接口中 SeekableByteChannelread 在类中 FileChannelIOExceptionpublic final int write(ByteBuffer src) throws IOException
write 在接口中 SeekableByteChannelwrite 在接口中 WritableByteChannelwrite 在类中 FileChannelIOExceptionpublic final FileChannel truncate(long newLength) throws IOException
truncate 在接口中 SeekableByteChanneltruncate 在类中 FileChannelIOExceptionprotected abstract void implTruncate(long size)
throws IOException
size - the new sizeIOException - on failureCopyright © 2022. All rights reserved.