Package org.aksw.commons.io.input
Class ReadableChannelSourceOverPath
java.lang.Object
org.aksw.commons.io.input.ReadableChannelSourceOverPath
- All Implemented Interfaces:
HasArrayOps<byte[]>,ReadableChannelFactory<byte[]>,ReadableChannelSource<byte[]>
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionArrayOps<byte[]>ReadableChannel<byte[]>newReadableChannel(com.google.common.collect.Range<Long> range) Offsets typically start with 0 but the interface contract leaves that unspecifiedlongsize()The size; -1 if unknownMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.aksw.commons.io.input.ReadableChannelFactory
newReadableChannel, newReadableChannelMethods inherited from interface org.aksw.commons.io.input.ReadableChannelSource
newReadableChannel
-
Field Details
-
path
-
predefinedSize
protected long predefinedSize
-
-
Constructor Details
-
ReadableChannelSourceOverPath
- Parameters:
path-predefinedSize- If the value is non-negative thensize()returns this value rather than invokingFiles.size(Path).
-
-
Method Details
-
getArrayOps
- Specified by:
getArrayOpsin interfaceHasArrayOps<byte[]>
-
newReadableChannel
public ReadableChannel<byte[]> newReadableChannel(com.google.common.collect.Range<Long> range) throws IOException Description copied from interface:ReadableChannelFactoryOffsets typically start with 0 but the interface contract leaves that unspecified- Specified by:
newReadableChannelin interfaceReadableChannelFactory<byte[]>- Throws:
IOException
-
size
Description copied from interface:ReadableChannelSourceThe size; -1 if unknown- Specified by:
sizein interfaceReadableChannelSource<byte[]>- Throws:
IOException
-