|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.io.InputStream
java.io.FilterInputStream
java.io.DataInputStream
edu.rice.cs.cunit.util.PositionDataInputStream
public final class PositionDataInputStream
A DataInputStream that makes the position in the stream available.
| Field Summary | |
|---|---|
protected PositionInputStream |
_in
Delegee. |
| Fields inherited from class java.io.FilterInputStream |
|---|
in |
| Constructor Summary | |
|---|---|
PositionDataInputStream(PositionInputStream in)
Create a new PositionInputStream based on the stream given. |
|
| Method Summary | |
|---|---|
long |
getPosition()
Get the stream position. |
| Methods inherited from class java.io.DataInputStream |
|---|
read, read, readBoolean, readByte, readChar, readDouble, readFloat, readFully, readFully, readInt, readLine, readLong, readShort, readUnsignedByte, readUnsignedShort, readUTF, readUTF, skipBytes |
| Methods inherited from class java.io.FilterInputStream |
|---|
available, close, mark, markSupported, read, reset, skip |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected PositionInputStream _in
| Constructor Detail |
|---|
public PositionDataInputStream(PositionInputStream in)
in - input stream| Method Detail |
|---|
public long getPosition()
Get the stream position.
Eventually, the position will roll over to a negative number. Reading 1 Tb per second, this would occur after approximately three months. Applications should account for this possibility in their design.
getPosition in interface ProvidesInputStreamPosition
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||