|
Jive Forums API (5.5.8) Developer Javadocs | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.jivesoftware.forum.ForumMessageIterator
com.jivesoftware.forum.database.ForumMessageBlockIterator
public class ForumMessageBlockIterator
A iterator for blocks of message ID's.
| Field Summary |
|---|
| Fields inherited from class com.jivesoftware.forum.ForumMessageIterator |
|---|
EMPTY_ITERATOR |
| Constructor Summary | |
|---|---|
protected |
ForumMessageBlockIterator(long[] block,
CachedPreparedStatement query,
int startIndex,
int endIndex,
int objectType,
long objectID)
Constructs a new ForumMessageBlockIterator. |
| Method Summary | |
|---|---|
boolean |
hasNext()
Returns true if this iterator has more messages when traversing the list in the forward direction. |
boolean |
hasPrevious()
Returns true if this list iterator has more messages when traversing the list in the reverse direction. |
java.lang.Object |
next()
Returns the next message in the list. |
java.lang.Object |
previous()
Returns the previous element in the list. |
void |
setIndex(long messageID)
Sets the index for the iteration to the specified message ID. |
| Methods inherited from class com.jivesoftware.forum.ForumMessageIterator |
|---|
remove |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected ForumMessageBlockIterator(long[] block,
CachedPreparedStatement query,
int startIndex,
int endIndex,
int objectType,
long objectID)
block - the array of id's to iterate through.query - the query used to select the block.startIndex - the starting index in the block to being iteration at.endIndex - the endeding index in the set to end iteration at. This
may or not be in the current block. If it ends after the current
block, the next block will be loaded automatically as necessary.objectType - the object type associated with this block.objectID - the ID of the object associated with this block.| Method Detail |
|---|
public boolean hasNext()
ForumMessageIterator
hasNext in interface java.util.IteratorhasNext in class ForumMessageIteratorpublic boolean hasPrevious()
ForumMessageIterator
hasPrevious in class ForumMessageIterator
public java.lang.Object next()
throws java.util.NoSuchElementException
ForumMessageIterator
next in interface java.util.Iteratornext in class ForumMessageIteratorjava.util.NoSuchElementException - if the iteration has no next element.public java.lang.Object previous()
ForumMessageIterator
previous in class ForumMessageIteratorpublic void setIndex(long messageID)
ForumMessageIteratorImplementation note: a performance setting allows an optional short-term query cache so that object invalidations are delayed for a period of time. This can mean that trying to set the index for a newly created message can fail. Ensure that this performance setting is disabled, or refrain from calling this method with newly created messages.
setIndex in class ForumMessageIterator
|
Jive Forums Project Page | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||