|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.asyncobjects.io.BinaryData.ByteIterator
public abstract static class BinaryData.ByteIterator
A base class for byte iterators.
Field Summary | |
---|---|
protected int |
current
current position |
protected int |
limit
current position |
Method Summary | |
---|---|
protected void |
advanceNext()
Subclasses call this method to ensure that iterator could move further |
protected void |
checkNext()
Subclass call this method to ensure that it is possible to advance further. |
boolean |
hasNext()
|
int |
next()
|
abstract byte[] |
nextArray(byte[] target,
int targetStart,
int size)
Copy data to array |
abstract byte |
nextByte()
|
int |
nextInt()
Get next big endian int. |
long |
nextLong()
Get next big endian long. |
short |
nextShort()
Get big endian short at the specified posion. |
abstract BinaryData |
nextSubrange(int length)
Next subrange |
abstract byte |
peekByte()
|
int |
position()
|
void |
skip(int n)
Skip n bytes |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected int current
protected int limit
Method Detail |
---|
public final int position()
public final boolean hasNext()
public final int next()
nextByte()
protected final void advanceNext()
protected void checkNext()
public final void skip(int n)
n
- amount of bytes to skippublic abstract byte nextByte()
public final int nextInt()
public final long nextLong()
public final short nextShort()
public abstract BinaryData nextSubrange(int length)
length
- a subrange length
public abstract byte[] nextArray(byte[] target, int targetStart, int size)
target
- a target arraytargetStart
- start in array to copysize
- a size to copy
public abstract byte peekByte()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |