public final class ChannelProxy extends SharedCloseableImpl
Constructor and Description |
---|
ChannelProxy(ChannelProxy copy) |
ChannelProxy(java.io.File file) |
ChannelProxy(java.lang.String path) |
ChannelProxy(java.lang.String filePath,
java.nio.channels.FileChannel channel) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
filePath() |
int |
getFileDescriptor() |
java.nio.MappedByteBuffer |
map(java.nio.channels.FileChannel.MapMode mode,
long position,
long size) |
static java.nio.channels.FileChannel |
openChannel(java.io.File file) |
int |
read(java.nio.ByteBuffer buffer,
long position) |
ChannelProxy |
sharedCopy() |
long |
size() |
java.lang.String |
toString() |
long |
transferTo(long position,
long count,
java.nio.channels.WritableByteChannel target) |
addTo, close, close, isCleanedUp
public ChannelProxy(java.lang.String path)
public ChannelProxy(java.io.File file)
public ChannelProxy(java.lang.String filePath, java.nio.channels.FileChannel channel)
public ChannelProxy(ChannelProxy copy)
public static java.nio.channels.FileChannel openChannel(java.io.File file)
public ChannelProxy sharedCopy()
public java.lang.String filePath()
public int read(java.nio.ByteBuffer buffer, long position)
public long transferTo(long position, long count, java.nio.channels.WritableByteChannel target)
public java.nio.MappedByteBuffer map(java.nio.channels.FileChannel.MapMode mode, long position, long size)
public long size()
public int getFileDescriptor()
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2019 The Apache Software Foundation