Class VeniceAvroFileIterator
- java.lang.Object
-
- com.linkedin.venice.hadoop.input.recordreader.avro.VeniceAvroFileIterator
-
- All Implemented Interfaces:
VeniceRecordIterator
,java.io.Closeable
,java.lang.AutoCloseable
public class VeniceAvroFileIterator extends java.lang.Object implements VeniceRecordIterator
-
-
Constructor Summary
Constructors Constructor Description VeniceAvroFileIterator(org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.fs.Path hdfsPath, AbstractAvroRecordReader<org.apache.avro.mapred.AvroWrapper<org.apache.avro.generic.IndexedRecord>,org.apache.hadoop.io.NullWritable> recordReader)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
byte[]
getCurrentKey()
Return the current key.byte[]
getCurrentValue()
Return the current value.boolean
next()
Proceed to next record, returns false if there is no more records.
-
-
-
Constructor Detail
-
VeniceAvroFileIterator
public VeniceAvroFileIterator(org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.fs.Path hdfsPath, AbstractAvroRecordReader<org.apache.avro.mapred.AvroWrapper<org.apache.avro.generic.IndexedRecord>,org.apache.hadoop.io.NullWritable> recordReader)
-
-
Method Detail
-
getCurrentKey
public byte[] getCurrentKey()
Description copied from interface:VeniceRecordIterator
Return the current key. This method should return same value until `next` is called.- Specified by:
getCurrentKey
in interfaceVeniceRecordIterator
-
getCurrentValue
public byte[] getCurrentValue()
Description copied from interface:VeniceRecordIterator
Return the current value. This method should return same value until `next` is called.- Specified by:
getCurrentValue
in interfaceVeniceRecordIterator
-
next
public boolean next()
Description copied from interface:VeniceRecordIterator
Proceed to next record, returns false if there is no more records.- Specified by:
next
in interfaceVeniceRecordIterator
-
close
public void close() throws java.io.IOException
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Specified by:
close
in interfacejava.io.Closeable
- Throws:
java.io.IOException
-
-