Package org.apache.avro.mapreduce
Class AvroSequenceFileInputFormat.AvroSequenceFileRecordReader
java.lang.Object
org.apache.hadoop.mapreduce.RecordReader<K,V>
org.apache.avro.mapreduce.AvroSequenceFileInputFormat.AvroSequenceFileRecordReader
- All Implemented Interfaces:
Closeable
,AutoCloseable
- Enclosing class:
AvroSequenceFileInputFormat<K,
V>
Reads records from a SequenceFile that supports Avro data.
This class is based on Hadoop's SequenceFileRecordReader, modified to construct an AvroSequenceFile.Reader instead of a SequenceFile.Reader.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
float
void
initialize
(InputSplit split, TaskAttemptContext context) boolean
-
Constructor Details
-
AvroSequenceFileRecordReader
protected AvroSequenceFileRecordReader()
-
-
Method Details
-
initialize
public void initialize(InputSplit split, TaskAttemptContext context) throws IOException, InterruptedException - Specified by:
initialize
in classRecordReader<K,
V> - Throws:
IOException
InterruptedException
-
nextKeyValue
- Specified by:
nextKeyValue
in classRecordReader<K,
V> - Throws:
IOException
InterruptedException
-
getCurrentKey
- Specified by:
getCurrentKey
in classRecordReader<K,
V>
-
getCurrentValue
- Specified by:
getCurrentValue
in classRecordReader<K,
V>
-
getProgress
- Specified by:
getProgress
in classRecordReader<K,
V> - Throws:
IOException
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in classRecordReader<K,
V> - Throws:
IOException
-