public interface ByteIterator extends Iterator<Byte>
This class implements the Iterator
interface. However, for performance reasons,
it is preferable to use its nextByte()
method directly in order to avoid
result boxing.
Modifier and Type | Method and Description |
---|---|
byte |
nextByte()
Returns the next byte from the sequence and increments the byte position.
|
forEachRemaining, hasNext, next, remove
byte nextByte()
When there is no next byte to be read from the stream, this method throws
a NoSuchElementException
. Use Iterator.hasNext()
to detect this condition.
NoSuchElementException
- if there are no more bytes in the streamCopyright © 2016. All rights reserved.