@Override public boolean markSupported() { open(); return this.input.markSupported(); }
static public StreamableInput input(Path path) { Objects.requireNonNull(path, "path cannot be null"); if (!Files.exists(path)) { throw new FileNotFoundException("Path " + path + " not found"); } long size; try { size = Files.size(path); } catch (IOException e) { throw new BlazeException(e.getMessage(), e); } return new StreamableInput(new DeferredFileInputStream(path), path.getFileName().toString(), path, size); }
static public StreamableInput input(Path path) { Objects.requireNonNull(path, "path cannot be null"); if (!Files.exists(path)) { throw new FileNotFoundException("Path " + path + " not found"); } long size; try { size = Files.size(path); } catch (IOException e) { throw new BlazeException(e.getMessage(), e); } return new StreamableInput(new DeferredFileInputStream(path), path.getFileName().toString(), path, size); }
@Override public synchronized void mark(int readlimit) { open(); this.input.mark(readlimit); }
@Override public int read() throws IOException { open(); return this.input.read(); }
@Override public int read(byte[] b, int off, int len) throws IOException { open(); return this.input.read(b, off, len); }
@Override public long skip(long n) throws IOException { open(); return this.input.skip(n); }
@Override public int read() throws IOException { open(); return this.input.read(); }
@Override public long skip(long n) throws IOException { open(); return this.input.skip(n); }
@Override public int read(byte[] b) throws IOException { open(); return this.input.read(b); }
@Override public int available() throws IOException { open(); return this.input.available(); }
@Override public int read(byte[] b, int off, int len) throws IOException { open(); return this.input.read(b, off, len); }
@Override public int read(byte[] b) throws IOException { open(); return this.input.read(b); }
@Override public synchronized void reset() throws IOException { open(); this.input.reset(); }
@Override public boolean markSupported() { open(); return this.input.markSupported(); }
@Override public synchronized void reset() throws IOException { open(); this.input.reset(); }
@Override public synchronized void mark(int readlimit) { open(); this.input.mark(readlimit); }
@Override public int available() throws IOException { open(); return this.input.available(); }