Class NioBufferedFileInputStream

All Implemented Interfaces:
Closeable, AutoCloseable

public final class NioBufferedFileInputStream extends InputStream
InputStream implementation which uses direct buffer to read a file to avoid extra copy of data between Java and native memory which happens when using BufferedInputStream. Unfortunately, this is not something already available in JDK, supports reading a file using nio, but does not support buffering.