public interface FileReader<D> extends Iterator<D>, Iterable<D>, Closeable
Modifier and Type | Method and Description |
---|---|
Schema |
getSchema()
Return the schema for data in this file.
|
D |
next(D reuse)
Read the next datum from the file.
|
boolean |
pastSync(long position)
Return true if past the next synchronization point after a position.
|
void |
sync(long position)
Move to the next synchronization point after a position.
|
long |
tell()
Return the current position in the input.
|
Schema getSchema()
D next(D reuse) throws IOException
reuse
- an instance to reuse.NoSuchElementException
- if no more remain in the file.IOException
void sync(long position) throws IOException
pastSync(long)
with the end point before each call to Iterator.next()
.IOException
boolean pastSync(long position) throws IOException
IOException
long tell() throws IOException
IOException
Copyright © 2009–2016 The Apache Software Foundation. All rights reserved.