/** * Extracts file to a directory. Read mode only. * * @param uriOrPath * path or uri to extract to. * @throws IOException */ public void exportData(String uriOrPath) throws IOException { exportData(uriOrPath, NamingStrategy.KEY, new ExtractionState(), false, 0); }
/** * @param paths * @return all the file starting with "part" in the paths requested * @throws IOException */ public static Path[] getInputPaths(String[] paths) throws IOException { return SequenceFileUtility.getFilePaths(paths, "part"); }
/** * Get the filesystem associated with a uri. * * @param uri * @return the filesystem * @throws IOException */ public FileSystem getFileSystem(URI uri) throws IOException { return getFileSystem(uri, config); }
public SequenceFileUtility(String uriOrPath, CompressionType compressionType, Map<String, String> metadata) throws IOException { this.compressionType = compressionType; setup(convertToURI(uriOrPath), false); }
/** * Search for the record identified by queryKey. Uses a linear search from * the beginning of the file. * * @param queryKey * @return the found value, or null. */ public V find(K queryKey) { return find(queryKey, 0); }
public SequenceFileUtility(URI uri, CompressionType compressionType, Map<String, String> metadata) throws IOException { this.compressionType = compressionType; setup(uri, false); }
@Override public KeyProvider<Text> getKeyProvider() { return new SequenceFileUtility.RelativePathFilenameKeyProvider(); } },
@Override public Text getKey(FileSystem fs, Path path, Path base) { return this.getKey(fs, path); } }
@Override public KeyProvider<Text> getKeyProvider() { return new SequenceFileUtility.MD5UUIDKeyProvider(); } },
@Override public KeyProvider<Text> getKeyProvider() { return new SequenceFileUtility.FilenameKeyProvider(); } },
@Override public Text getKey(FileSystem fs, Path path, Path base) { return this.getKey(fs, path); } }
/** * All the files starting with "part" in the paths which look like: "paths[i]/subdir * @param paths * @param subdir * @return the paths to the part files * @throws IOException */ public static Path[] getInputPaths(String[] paths, String subdir) throws IOException { return SequenceFileUtility.getFilePaths(paths, subdir, "part"); }
/** * Extracts file to a directory. Read mode only. * * @param uriOrPath * path or uri to extract to. * @throws IOException */ public void exportData(String uriOrPath) throws IOException { exportData(uriOrPath, NamingStrategy.KEY, new ExtractionState(), false, 0); }
/** * Get the filesystem associated with a uri. * * @param uri * @return the filesystem * @throws IOException */ public FileSystem getFileSystem(URI uri) throws IOException { return getFileSystem(uri, config); }
/** * Search for the record identified by queryKey. Uses a linear search from * the beginning of the file. * * @param queryKey * @return the found value, or null. */ public V find(K queryKey) { return find(queryKey, 0); }
public SequenceFileUtility(URI uri, CompressionType compressionType, Map<String, String> metadata) throws IOException { this.compressionType = compressionType; setup(uri, false); }
/** * @param paths * @return all the file starting with "part" in the paths requested * @throws IOException */ public static Path[] getInputPaths(String[] paths) throws IOException { return SequenceFileUtility.getFilePaths(paths, "part"); }
/** * Extracts file to a directory. Read mode only. * * @param fs * filesystem of output file * @param dirPath * path to extract to */ public void exportData(FileSystem fs, Path dirPath) { exportData(fs, dirPath, NamingStrategy.KEY, new ExtractionState(), false, 0); }
/** * All the files starting with "part" in the paths which look like: "paths[i]/subdir * @param paths * @param subdir * @return the paths to the part files * @throws IOException */ public static Path[] getInputPaths(String[] paths, String subdir) throws IOException { return SequenceFileUtility.getFilePaths(paths, subdir, "part"); }
/** * Extracts file to a directory. Read mode only. * * @param fs * filesystem of output file * @param dirPath * path to extract to */ public void exportData(FileSystem fs, Path dirPath) { exportData(fs, dirPath, NamingStrategy.KEY, new ExtractionState(), false, 0); }