Interface ProcessList
- All Superinterfaces:
AutoCloseable, Closeable, OsidList, OsidList
Like all OsidLists , ProcessList provides a means for
accessing Process elements sequentially either one at a time or
many at a time. Examples:
while (pl.hasNext()) {
Process process = pl.getNextProcess();
}
or
while (pl.hasNext()) {
Process[] processes = pl.getNextProcesses(pl.available());
}
-
Method Summary
Modifier and TypeMethodDescriptionGets the nextProcessin this list.Process[]getNextProcesses(long n) Gets the next set ofProcesselements in this list which must be less than or equal to the return fromavailable().
-
Method Details
-
getNextProcess
Gets the nextProcessin this list.- Returns:
- the next
Processin this list. ThehasNext()method should be used to test that a nextProcessis available before calling this method. - Throws:
IllegalStateException- no more elements available in this listOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
getNextProcesses
Gets the next set ofProcesselements in this list which must be less than or equal to the return fromavailable().- Parameters:
n- the number ofProcesselements requested which must be less than or equal toavailable()- Returns:
- an array of
Processelements. The length of the array is less than or equal to the number specified. - Throws:
IllegalStateException- no more elements available in this listOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-