GPL_Reference::operator=(). Return the set.
GPL_Set<T> operator|(const GPL_Set<T> & set)
Return a new set containing all of the members of the set and all of the
member of set. The new set will not contain duplicate entries.
GPL_Set<T> operator&(const GPL_Set<T> & set)
Return a new set containing all of the members of the set which are also
members of set. The new set will not contain duplicate entries.
GPL_Set<T> operator-(const GPL_Set<T> & set)
Return a new set containing all of the members of the set which are
not also members of set. The new set will not contain duplicate
entries.
inline GPL_Boolean operator==(const GPL_Set<T> & set) const
Return TRUE if the set and set are exactly equivalent and
FALSE otherwise.
inline GPL_Boolean operator!=(const GPL_Set<T> & set) const
Return FALSE if the set and set are exactly equivalent and
TRUE otherwise.
inline T & operator[](const unsigned long i)
Return a reference to the i-th element in the set, counting from
zero. This method blindly steps into the data and is invalid if the
object is null or the index out-of-bounds.
inline const T & operator[](const unsigned long i) const
Return a reference to the i-th element in the set, counting from
zero. This method blindly steps into the data and is invalid if the
object is null or the index out-of-bounds. This method makes a private
copy of the data first, since the caller may modify the internal state.
inline unsigned long GetSize(void) const
Return the number of elements for which the set has storage.
inline const T & GetElement(const unsigned long i) const
Return a reference to the i-th element in the set, counting from
zero. This method blindly steps into the data and is invalid if the
object is null or the index out-of-bounds.
inline GPL_Boolean Contains(const T & data) const
Return TRUE if the set contains data and FALSE
otherwise.
GPL_Boolean Contains(const GPL_Set<T> & set) const
Return TRUE if the set contains every member of set and
FALSE otherwise.
virtual long Compare(const GPL_Set<T> & set) const
Return 0 if the set contains every member of set and
set contains every member of the set.
Return 1 if the set contains every member of set and
set does not contain every member of the set.
Return -1 if the set does not contain every member of set
and set contains every member of the set.
inline void Clear(void)
Remove all elements from the set.
void Insert(const T & data, const unsigned long at = 0)
Insert the element data into the set if and only if data
does already exist in the set. The argument at is ignored; it
exists to maintain compatability with GPL_List.
void Remove(const T & data)
Remove the element data, if present, from the set.
GPL_Set<T> Join(const GPL_Set<T> & set) const
Return a new set containing all of the members of the set and all of the
member of set. The new set will not contain duplicate entries.
GPL_Set<T> Intersect(const GPL_Set<T> & set) const
Return a new set containing all of the members of the set which are also
members of set. The new set will not contain duplicate entries.
GPL_Set<T> Subtract(const GPL_Set<T> & set) const
Return a new set containing all of the members of the set which are
not also members of set. The new set will not contain duplicate
entries.