Package herddb.utils
Class ODirectFileInputStream
- java.lang.Object
-
- java.io.InputStream
-
- herddb.utils.ODirectFileInputStream
-
- All Implemented Interfaces:
Closeable,AutoCloseable
public class ODirectFileInputStream extends InputStream
O_DIRECTInputStream implementation.- Author:
- diego.salvi
-
-
Constructor Summary
Constructors Constructor Description ODirectFileInputStream(Path path)ODirectFileInputStream(Path path, int batchBlocks)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intavailable()voidclose()intgetAlignment()intgetBatchBlocks()FileChannelgetFileChannel()intgetReadBlocks()intread()intread(byte[] b, int off, int len)-
Methods inherited from class java.io.InputStream
mark, markSupported, nullInputStream, read, readAllBytes, readNBytes, readNBytes, reset, skip, transferTo
-
-
-
-
Constructor Detail
-
ODirectFileInputStream
public ODirectFileInputStream(Path path) throws IOException
- Throws:
IOException
-
ODirectFileInputStream
public ODirectFileInputStream(Path path, int batchBlocks) throws IOException
- Throws:
IOException
-
-
Method Detail
-
getAlignment
public int getAlignment()
-
getReadBlocks
public int getReadBlocks()
-
getBatchBlocks
public int getBatchBlocks()
-
getFileChannel
public FileChannel getFileChannel()
-
read
public int read() throws IOException- Specified by:
readin classInputStream- Throws:
IOException
-
read
public int read(byte[] b, int off, int len) throws IOException- Overrides:
readin classInputStream- Throws:
IOException
-
available
public int available() throws IOException- Overrides:
availablein classInputStream- Throws:
IOException
-
close
public void close() throws IOException- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classInputStream- Throws:
IOException
-
-