Crate sequencefile[−][src]
Expand description
Prototype streaming library for reading Hadoop sequencefiles
Example
ⓘ
let path = Path::new("/path/to/seqfile");
let file = File::open(&path).unwrap();
let seqfile = match sequencefile::Reader::new(file) {
Ok(val) => val,
Err(err) => panic!("Failed to open sequence file: {}", err),
};
// Returns a Result<(ByteString, ByteString)>, where a ByteString is a Vec<u8>
// An Err from this will signal an unrecoverable error. Next call to Iterator
// Returns None
for kv in seqfile {
println!("{:?}", kv);
}
Re-exports
Modules
Structs
Sequencefile header, metadata about the file, e.g. key/value types, version, compression and some internal state for properly decoding
hadoop.io.Text
Enums
Compression codec
Type of compression used on the sequencefile.
Type Definitions
Convenience typedef