multimap


template <class K, class T>
class multimap : public Semaphore
{
 public:

  // *** typedefs ***
 
  typedef int (*keyCompare)(const K&,const K&);

  // *** iterators ***

  typedef mapIterator<K,T> iterator;

  typedef constMapIterator<K,T> const_iterator;

  // *** Constructors, Destructor, Operators ***

  multimap(keyCompare Compare=compare);

  multimap(const multimap<K,T>& Copy);

  ~multimap();

  multimap<K,T>& operator=(const multimap<K,T>& Copy);

  void* operator new(size_t s);

  void operator delete(void* p);

  operator keyCompare() const;

  // *** Methods ***

  iterator after(const K& Key) const;

  iterator afterEquals(const K& Key) const;

  iterator before(const K& Key) const;

  iterator beforeEquals(const K& Key) const;

  iterator begin();

  const_iterator begin() const;

  Unsigned depth() const; 

  iterator end();

  const_iterator end() const;

  void erase();

  Unsigned erase(const K& Key);

  void erase(iterator itemRemove);

  list<T> find(const K& Key) const;

  iterator find(const K& Key,
                Unsigned Index) const;

  iterator insert(const K& Key,
                  const T& Data);

  iterator insertFront(const K& Key,
                       const T& Data);

  iterator insertWithHint(const K& Key,
                          const T& Data,
                          iterator Hint);

  iterator insertFrontWithHint(const K& Key,
                               const T& Data,
                               iterator Hint);

  Unsigned length() const;

  Unsigned length(const K& Key) const;

  Void range(const K& Key,
             iterator& First,
             iterator& Last) const;
};