Mission Base

Program Base Library Functions

int pblSetContainsAll

( PblSet* set, void* collection )

Returns a value > 0 if this set contains all of the elements in the specified collection.

Documentation

Returns a value > 0 if this set contains all of the elements in the specified collection.

This implementation iterates over the specified collection, checking each element returned by the iterator in turn to see if it's contained in this set. If all elements are so contained a value > 0 is returned, otherwise 0.

For hash sets this method has a time complexity of O(M) and for hash sets this method has a time complexity of O(Log N * M), with N being the size of the set and M being the size of the collection.

Parameters:
set - The set to use
collection - The collection to be checked for containment in this set.
Returns:
int rc > 0: The set contains all of the elements in the specified collection.
int rc == 0: The set does not contain all of the elements.
int rc < 0: An error, see pbl_errno:
PBL_ERROR_PARAM_COLLECTION - The collection cannot be iterated.
PBL_ERROR_CONCURRENT_MODIFICATION - The collection was modified concurrently.

Alphabetic index



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