Mission Base

Program Base Library Functions

int pblIteratorRemove

( PblIterator* iterator )

Removes from the underlying list or tree set the last element returned by the iterator.

Documentation

Removes from the underlying list or tree set the last element returned by the iterator.

This method can be called only once per call to next or previous. It can be made only if pblIteratorAdd() has not been called after the last call to next or previous.

For array lists this method has a time complexity of O(N), with N being the number of elements in the underlying list.

For linked lists and hash sets this method has a time complexity of O(1).

For tree sets this method has a time complexity of O(Log N), with N being the number of elements in the underlying collection.

Parameters:
iterator - The iterator to remove the next element from
Returns:
int rc >= 0: The size of the collection.
int rc < 0: An error, see pbl_errno:
PBL_ERROR_NOT_ALLOWED - The the next or previous method has not yet been called, or the remove method has already been called after the last call to the next or previous method.
PBL_ERROR_CONCURRENT_MODIFICATION - The underlying list or tree set was modified concurrently.
PBL_ERROR_PARAM_LIST - The underlying collection is neither a list nor a tree set.

Alphabetic index



This page was generated with the help of DOC++.