Main Page Class Hierarchy Compound List Compound Members
EnumItems Class Reference
Implements the Enumeration interface generates a series of elements, one at a time. Successive calls to the getNext method return successive elements of the series.
More...
List of all members.
Public Methods |
bool | getNext (TaskOutputHandlePtr &taskOutputHandle) throw (SoamException) |
| Returns the next item in the enumeration. If the enumeration's current position is at the end, false will be returned and the taskOutputHandle will be invalid, otherwise true will be returned and the taskOutputHandle will be valid.
|
void | reset () throw (SoamException) |
| Places the enumeration current position to the beginning. A subsequent call to getNext() will result in the 1st item being returned.
|
void | skip (SoamULong skipCount) throw (SoamException) |
| Skips over the next count items in the enumerator. If the number is greater than the number of items left to enumerate, the enumerator’s current position will be set to the end.
|
SoamULong | getCount () throw (SoamException) |
| Retrieve a count of the number of items in the enumeration.
|
EnumItemsPtr | clone () throw (SoamException) |
| Makes a copy of the enumerator.
|
Friends |
class | Session |
Detailed Description
Implements the Enumeration interface generates a series of elements, one at a time. Successive calls to the getNext method return successive elements of the series.
Session::fetchTaskOutput will return a smart pointer of EnumItems. You could use it to enumerate through the responses from SOAM.
EnumItemsPtr enumOutput = sesPtr->fetchTaskOutput(tasksToSend, globalConst(TIMEOUT_INFINITE)); TaskOutputHandlePtr output; while(enumOutput->getNext(output)) { ...... }
NOTE:
1. It is always best to access a pointer to this type of object through the appropriate smart pointer type instead of using a raw pointer.
2. If any of the methods of this class are called after the main(...) method exits, the client or service process may behave in an undefined manner (for example, hang or terminate abnormally).
-
See also:
-
EnumItemsPtr , Session::fetchTaskOutput , TaskOutputHandle
Member Function Documentation
|
Returns the next item in the enumeration. If the enumeration's current position is at the end, false will be returned and the taskOutputHandle will be invalid, otherwise true will be returned and the taskOutputHandle will be valid.
-
Parameters:
-
-
Returns:
-
TRUE if there are more items in the enumeration, FALSE otherwise.
-
Exceptions:
-
-
See also:
-
TaskOutputHandle
|
|
Places the enumeration current position to the beginning. A subsequent call to getNext() will result in the 1st item being returned.
-
Exceptions:
-
|
|
Skips over the next count items in the enumerator. If the number is greater than the number of items left to enumerate, the enumerator’s current position will be set to the end.
-
Parameters:
-
skipCount |
[IN] - skipped record count. |
-
Exceptions:
-
|
|
Retrieve a count of the number of items in the enumeration.
-
Returns:
-
the number of Task objects in the EnumItems.
-
Exceptions:
-
|
|
Makes a copy of the enumerator.
Each enumerator can be accessed simultaneously without interference.
-
Returns:
-
a copy of the enumerator.
-
Exceptions:
-
|