Package org.apache.avro.mapred
Class SequenceFileReader<K,V>
java.lang.Object
org.apache.avro.mapred.SequenceFileReader<K,V>
- All Implemented Interfaces:
Closeable
,AutoCloseable
,Iterable<Pair<K,
,V>> Iterator<Pair<K,
,V>> org.apache.avro.file.FileReader<Pair<K,
V>>
public class SequenceFileReader<K,V>
extends Object
implements org.apache.avro.file.FileReader<Pair<K,V>>
A
FileReader
for sequence files.-
Constructor Summary
ConstructorsConstructorDescriptionSequenceFileReader
(File file) SequenceFileReader
(URI uri, Configuration c) SequenceFileReader
(SequenceFile.Reader reader, Configuration conf) -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
Methods inherited from interface java.util.Iterator
forEachRemaining
-
Constructor Details
-
SequenceFileReader
- Throws:
IOException
-
SequenceFileReader
- Throws:
IOException
-
SequenceFileReader
-
-
Method Details
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Throws:
IOException
-
remove
public void remove() -
iterator
-
getSchema
public org.apache.avro.Schema getSchema()- Specified by:
getSchema
in interfaceorg.apache.avro.file.FileReader<K>
-
hasNext
public boolean hasNext() -
next
-
next
- Specified by:
next
in interfaceorg.apache.avro.file.FileReader<K>
- Throws:
IOException
-
sync
- Specified by:
sync
in interfaceorg.apache.avro.file.FileReader<K>
- Throws:
IOException
-
pastSync
- Specified by:
pastSync
in interfaceorg.apache.avro.file.FileReader<K>
- Throws:
IOException
-
tell
- Specified by:
tell
in interfaceorg.apache.avro.file.FileReader<K>
- Throws:
IOException
-