Package org.jgroups.util
Class MessageBatch.BatchIterator
- java.lang.Object
-
- org.jgroups.util.MessageBatch.BatchIterator
-
- All Implemented Interfaces:
java.util.Iterator<Message>
,MessageIterator
- Enclosing class:
- MessageBatch
protected class MessageBatch.BatchIterator extends java.lang.Object implements MessageIterator
Iterates over non-null elements of a batch, skipping null elements
-
-
Field Summary
Fields Modifier and Type Field Description protected int
current_index
protected int
saved_index
-
Constructor Summary
Constructors Constructor Description BatchIterator(int saved_index)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
hasNext()
Message
next()
void
remove()
void
replace(Message msg)
Replaces the message at the current index with msg
-
-
-
Method Detail
-
hasNext
public boolean hasNext()
- Specified by:
hasNext
in interfacejava.util.Iterator<Message>
-
remove
public void remove()
- Specified by:
remove
in interfacejava.util.Iterator<Message>
-
replace
public void replace(Message msg)
Description copied from interface:MessageIterator
Replaces the message at the current index with msg- Specified by:
replace
in interfaceMessageIterator
-
-