1 // Copyright (c) 1994 James Clark
2 // See the file COPYING for copying permission.
4 #ifndef OwnerTable_INCLUDED
5 #define OwnerTable_INCLUDED 1
7 #include "PointerTable.h"
10 namespace SP_NAMESPACE {
13 template<class T, class K, class HF, class KF>
14 class OwnerTable : public PointerTable<T *, K, HF, KF> {
19 void swap(OwnerTable<T, K, HF, KF> &x) {
20 PointerTable<T *, K, HF, KF>::swap(x);
23 OwnerTable(const OwnerTable<T, K, HF, KF> &);
24 void operator=(const OwnerTable<T, K, HF, KF> &);
27 template<class T, class K, class HF, class KF>
28 class OwnerTableIter : public PointerTableIter<T *, K, HF, KF> {
30 OwnerTableIter(const OwnerTable<T, K, HF, KF> &table)
31 : PointerTableIter<T *, K, HF, KF>(table) { }
34 template<class T, class K, class HF, class KF>
35 class CopyOwnerTable : public OwnerTable<T, K, HF, KF> {
38 CopyOwnerTable(const CopyOwnerTable<T, K, HF, KF> &tab) { *this = tab; }
39 void operator=(const CopyOwnerTable<T, K, HF, KF> &tab);
46 #endif /* not OwnerTable_INCLUDED */
48 #ifdef SP_DEFINE_TEMPLATES
49 #include "OwnerTable.cxx"