@Override InputStream openStream(final int index) throws IOException { return FileHelper.getInputStream(_files[index]); } }
@Override InputStream openStream(final int index) throws IOException { return FileHelper.getInputStream(_files[index]); } }
private void addResourceIfExists(Configuration conf, File hadoopConfigurationDirectory, String filename) { final File file = new File(hadoopConfigurationDirectory, filename); if (file.exists()) { final InputStream inputStream = FileHelper.getInputStream(file); conf.addResource(inputStream, filename); } }
private static void addResourceIfExists(final Configuration conf, final File hadoopConfigurationDirectory, final String filename) { final File file = new File(hadoopConfigurationDirectory, filename); if (file.exists()) { final InputStream inputStream = FileHelper.getInputStream(file); conf.addResource(inputStream, filename); } }
@Override public InputStream read() throws ResourceException { if (_file.isDirectory()) { return new DirectoryInputStream(); } final InputStream in = FileHelper.getInputStream(_file); return in; }
@Override public InputStream read() throws ResourceException { if (_file.isDirectory()) { return new DirectoryInputStream(); } final InputStream in = FileHelper.getInputStream(_file); return in; }
final InputStream inputStream = FileHelper.getInputStream(file); try { scanInputStream(inputStream, classLoader, strictClassLoader);
final InputStream inputStream = FileHelper.getInputStream(file); try { scanInputStream(inputStream, classLoader, strictClassLoader);
public static void copy(File from, File to) throws IllegalStateException { assert from.exists(); final InputStream in = getInputStream(from); try { final OutputStream out = getOutputStream(to); try { copy(in, out); } finally { safeClose(out); } } finally { safeClose(in); } }
public static void copy(File from, File to) throws IllegalStateException { assert from.exists(); final InputStream in = getInputStream(from); try { final OutputStream out = getOutputStream(to); try { copy(in, out); } finally { safeClose(out); } } finally { safeClose(in); } }
final InputStream in = FileHelper.getInputStream(tempFile); try { _updateCallback.getResource().write(new Action<OutputStream>() {
final InputStream in = FileHelper.getInputStream(tempFile); try { _updateCallback.getResource().write(new Action<OutputStream>() {