00001 #ifndef MMANN_FCS_STACK_STORAGE 00002 #define MMANN_FCS_STACK_STORAGE 00003 00011 00012 #include "CompareAlgorithms.h" 00013 #include "HashAlgorithms.h" 00014 #include "AGenericTree.h" 00015 #include "FCInternalHash.h" 00016 #include "GLIBHash.h" 00017 00018 class FCSIndirectCard; 00019 00021 class AFCSGenericStackStorage 00022 { 00023 public: 00025 virtual ~AFCSGenericStackStorage(); 00026 00031 virtual FCSIndirectCard* Insert(FCSIndirectCard* Card) = 0; 00032 }; 00033 00035 class FCTreeStackStorage : public AFCSGenericStackStorage 00036 { 00037 public: 00039 FCTreeStackStorage(); 00040 00042 virtual ~FCTreeStackStorage(); 00043 00048 virtual FCSIndirectCard* Insert(FCSIndirectCard* card); 00049 00050 protected: 00051 00053 AGenericTree<FCSIndirectCard, void>* m_Tree; 00054 }; 00055 00057 class FCAVLTreeStackStorage : public FCTreeStackStorage 00058 { 00059 public: 00061 FCAVLTreeStackStorage(ACompareNodesAlgorithm<FCSIndirectCard, void>* Compare); 00062 00064 virtual ~FCAVLTreeStackStorage(); 00065 }; 00066 00068 class FCAVLRedBlackTreeStackStorage : public FCTreeStackStorage 00069 { 00070 public: 00072 FCAVLRedBlackTreeStackStorage(ACompareNodesAlgorithm<FCSIndirectCard, void>* Compare); 00073 00075 virtual ~FCAVLRedBlackTreeStackStorage(); 00076 }; 00077 00079 class FCRedBlackTreeStackStorage : public FCTreeStackStorage 00080 { 00081 public: 00083 FCRedBlackTreeStackStorage(ACompareNodesAlgorithm<FCSIndirectCard, void>* Compare); 00084 00086 virtual ~FCRedBlackTreeStackStorage(); 00087 }; 00088 00090 class FCGLIBTreeStackStorage : public FCTreeStackStorage 00091 { 00092 public: 00094 FCGLIBTreeStackStorage(ACompareNodesAlgorithm<FCSIndirectCard, void>* Compare); 00095 00097 virtual ~FCGLIBTreeStackStorage(); 00098 }; 00099 00101 class FCHashStackStorage : public AFCSGenericStackStorage 00102 { 00103 public: 00105 FCHashStackStorage(); 00106 00108 virtual ~FCHashStackStorage(); 00109 00114 virtual FCSIndirectCard* Insert(FCSIndirectCard* card); 00115 00116 00117 protected: 00119 AGenericHash<FCSIndirectCard, void>* m_Hash; 00120 }; 00121 00123 class FCGLIBHashStackStorage : public FCHashStackStorage 00124 { 00125 public: 00126 00128 FCGLIBHashStackStorage(int SizeWanted, ACompareNodesAlgorithm<FCSIndirectCard, void>* Compare, 00129 AHashAlgorithm<FCSIndirectCard>* Hash); 00130 00132 virtual ~FCGLIBHashStackStorage(); 00133 }; 00134 00136 class FCInternalHashStackStorage : public FCHashStackStorage 00137 { 00138 public: 00140 FCInternalHashStackStorage(int SizeWanted, ACompareNodesAlgorithm<FCSIndirectCard, void>* Compare, 00141 AHashAlgorithm<FCSIndirectCard>* Hash); 00142 00144 virtual ~FCInternalHashStackStorage(); 00145 }; 00146 00147 #endif