public class FChannelBuffer extends SBCBuffer
channel, closeOnFinalize| Constructor and Description |
|---|
FChannelBuffer(FileChannel channel) |
| Modifier and Type | Method and Description |
|---|---|
void |
flush()
Запись содержимого на диск/память
|
void |
force(boolean metaData) |
FileChannel |
getFileChannel() |
FileLock |
lock() |
FileLock |
lock(long position,
long size,
boolean shared) |
MappedByteBuffer |
map(FileChannel.MapMode mode,
long position,
long size) |
static FChannelBuffer |
open(File file,
OpenOption... options) |
static FChannelBuffer |
open(File file,
Set<? extends OpenOption> options,
FileAttribute<?>... attrs) |
static FChannelBuffer |
open(Path path,
OpenOption... options) |
static FChannelBuffer |
open(Path path,
Set<? extends OpenOption> options,
FileAttribute<?>... attrs) |
long |
transferFrom(ReadableByteChannel src,
long position,
long count) |
long |
transferTo(long position,
long count,
WritableByteChannel target) |
FileLock |
tryLock() |
FileLock |
tryLock(long position,
long size,
boolean shared) |
public FChannelBuffer(FileChannel channel)
public static FChannelBuffer open(Path path, OpenOption... options)
public static FChannelBuffer open(Path path, Set<? extends OpenOption> options, FileAttribute<?>... attrs)
public static FChannelBuffer open(File file, OpenOption... options)
public static FChannelBuffer open(File file, Set<? extends OpenOption> options, FileAttribute<?>... attrs)
public FileChannel getFileChannel()
public FileLock lock()
public FileLock lock(long position, long size, boolean shared)
public FileLock tryLock()
public FileLock tryLock(long position, long size, boolean shared)
public void force(boolean metaData)
public void flush()
ContentBufferflush in interface ContentBufferflush in class SBCBufferpublic MappedByteBuffer map(FileChannel.MapMode mode, long position, long size)
public long transferFrom(ReadableByteChannel src, long position, long count)
public long transferTo(long position,
long count,
WritableByteChannel target)
Copyright © 2019. All rights reserved.