public final class ByteSequenceIterator extends Object implements Iterator<ByteBuffer>
Constructor and Description |
---|
ByteSequenceIterator(FSA fsa)
Create an instance of the iterator iterating over all automaton sequences.
|
ByteSequenceIterator(FSA fsa,
int node)
Create an instance of the iterator for a given node.
|
Modifier and Type | Method and Description |
---|---|
boolean |
hasNext()
Returns
true if there are still elements in this iterator. |
ByteBuffer |
next() |
void |
remove()
Not implemented in this iterator.
|
ByteSequenceIterator |
restartFrom(int node)
Restart walking from
node . |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEachRemaining
public ByteSequenceIterator(FSA fsa)
fsa
- The automaton to iterate over.public ByteSequenceIterator(FSA fsa, int node)
fsa
- The automaton to iterate over.node
- The starting node's identifier (can be the FSA.getRootNode()
).public ByteSequenceIterator restartFrom(int node)
node
. Allows iterator reuse.node
- Restart the iterator from node
.this
for call chaining.public boolean hasNext()
true
if there are still elements in this iterator.hasNext
in interface Iterator<ByteBuffer>
public ByteBuffer next()
next
in interface Iterator<ByteBuffer>
ByteBuffer
with the sequence corresponding to the
next final state in the automaton.public void remove()
remove
in interface Iterator<ByteBuffer>
Copyright © 2016. All rights reserved.