public interface PostEntryList extends OsidList
Like all OsidLists,
PostEntryList
provides a means for accessing PostEntry
elements
sequentially either one at a time or many at a time. Examples:
while (pel.hasNext()) { PostEntry post entry = pel.getNextPostEntry(); }or
while (pel.hasNext()) { PostEntry[] entries = pel.getNextPostEntries(pel.available()); }
Modifier and Type | Method and Description |
---|---|
PostEntry[] |
getNextPostEntries(long n)
Gets the next set of
PostEntry elements in this list. |
PostEntry |
getNextPostEntry()
Gets the next
PostEntry in this list. |
PostEntry getNextPostEntry() throws OperationFailedException
PostEntry
in this list. PostEntry
in this list. The
hasNext()
method should be used to test that a next
PostEntry
is available before calling this
method.IllegalStateException
- no more elements available in
this listOperationFailedException
- unable to complete requestmandatory
- This method must be implemented. PostEntry[] getNextPostEntries(long n) throws OperationFailedException
PostEntry
elements in this list.
The specified amount must be less than or equal to the return from
available().
n
- the number of PostEntry
elements requested
which must be less than or equal to available()
PostEntry
elements.
The length of the array is less than or equal to the number
specified.IllegalStateException
- no more elements available in
this listOperationFailedException
- unable to complete requestmandatory
- This method must be implemented.