Source: set.h


Annotated List
Files
Globals
Hierarchy
Index
// ##########################################################################
// ####                                                                  ####
// ####                      RTP Audio Server Project                    ####
// ####                    ============================                  ####
// ####                                                                  ####
// #### Set Template                                                     ####
// ####                                                                  ####
// #### Version 1.00  --  February 04, 2001                              ####
// ####                                                                  ####
// #### Copyright (C) 1999  Thomas Dreibholz                             ####
// ####               2000  Universität Bonn, Abt. IV                    ####
// ####               2001  EMail: Dreibholz@bigfoot.com                 ####
// ####                     WWW:   http://www.bigfoot.com/~dreibholz     ####
// ####                                                                  ####
// ##########################################################################


#ifndef SET_H
#define SET_H


#include "system.h"
#include "bag.h"


/**
  * This class implements the Set datatype template.
  *
  * @short   Set
  * @author  Thomas Dreibholz (Dreibholz@bigfoot.com)
  * @version 1.0
  */
template<class T> class Set : public Bag<T>
{
   // ====== Element add/remove functions ===================================
   public:
   /**
     * Add element to head of set, if not already in set.
     *
     * @param element Element to be added.
     * @return true, if element has been added; false, if not.
     */
   inline bool addHead(T element);

   /**
     * Add element to tail of set, if not already in set.
     *
     * @param element Element to be added.
     * @return true, if element has been added; false, if not.
     */
   inline bool addTail(T element);

   /**
     * Add element to set.
     *
     * @param element Element to be added.
     * @return true, if the element has been added; false, if not.
     */
   inline bool add(T element);
};


#include "set.icc"


#endif

Generated by: viper@odin on Sun Feb 4 18:54:51 2001, using kdoc 2.0a22.