00001 #ifndef FCS_TALON_STATE_WITH_LOCATIONS_H 00002 #define FCS_TALON_STATE_WITH_LOCATIONS_H 00003 00011 00012 #include "FCDebugState.h" 00013 #include "FCCompactState.h" 00014 #include "FCIndirectState.h" 00015 #include "FCSDebugStateWithLocations.h" 00016 #include "FCSCompactStateWithLocations.h" 00017 #include "FCSIndirectStateWithLocations.h" 00018 00019 class FCSDebugTalonStateWithLocations; 00020 class FCSCompactTalonStateWithLocations; 00021 class FCSIndirectTalonStateWithLocations; 00022 00024 class FCSDebugTalonStateData : public FCSTalonStateData 00025 { 00026 public: 00028 friend class FCSDebugTalonStateWithLocations; 00029 00031 FCSDebugTalonStateData(); 00032 00034 virtual ~FCSDebugTalonStateData(); 00035 00039 virtual void Copy(FCSTalonStateData* Data); 00040 00044 virtual int Compare(const FCSTalonStateData* TalonData); 00045 00050 FCSCard* GetTalon(int Position); 00051 00053 void KlondikeTalonQueueToStack(); 00054 00058 FCSCard* GetKlondikeTalonTopCard(); 00059 00060 protected: 00062 FCSDebugCard* m_Talon; 00063 }; 00064 00066 class FCSDebugTalonStateWithLocations : public FCSDebugStateWithLocations<FCSTalonStateWithLocations> 00067 { 00068 public: 00070 FCSDebugTalonStateWithLocations(); 00071 00073 virtual ~FCSDebugTalonStateWithLocations(); 00074 00078 virtual void Copy(FCSStateWithLocations* State); 00079 00081 virtual void Initialize(int NumberOfStacks); 00082 00084 virtual void CleanState(); 00085 00089 void CacheTalonStacks(FCInternalHash<FCSTalonStateData, void>* TalonHash); 00090 00094 void CreateTalons(int NumberOfTalons); 00095 00099 FCSTalonStateData* GetTalonData(); 00100 00102 void DecrementKlondikeTalonStack(); 00103 00104 protected: 00106 FCSDebugTalonStateData* m_TalonData; 00107 }; 00108 00109 00111 class FCSCompactTalonStateData : public FCSTalonStateData 00112 { 00113 public: 00115 friend class FCSCompactTalonStateWithLocations; 00116 00118 FCSCompactTalonStateData(); 00119 00121 virtual ~FCSCompactTalonStateData(); 00122 00126 virtual void Copy(FCSTalonStateData* Data); 00127 00131 virtual int Compare(const FCSTalonStateData* TalonData); 00132 00137 FCSCard* GetTalon(int Position); 00138 00140 void KlondikeTalonQueueToStack(); 00141 00145 FCSCard* GetKlondikeTalonTopCard(); 00146 00147 protected: 00149 FCSCompactCard* m_Talon; 00150 }; 00151 00153 class FCSCompactTalonStateWithLocations : public FCSCompactStateWithLocations<FCSTalonStateWithLocations> 00154 { 00155 public: 00157 FCSCompactTalonStateWithLocations(); 00158 00160 virtual ~FCSCompactTalonStateWithLocations(); 00161 00165 virtual void Copy(FCSStateWithLocations* State); 00166 00168 virtual void Initialize(int NumberOfStacks); 00169 00171 virtual void CleanState(); 00172 00176 void CacheTalonStacks(FCInternalHash<FCSTalonStateData, void>* TalonHash); 00177 00181 void CreateTalons(int NumberOfTalons); 00182 00186 FCSTalonStateData* GetTalonData(); 00187 00189 void DecrementKlondikeTalonStack(); 00190 00191 00192 protected: 00194 FCSCompactTalonStateData* m_TalonData; 00195 }; 00196 00198 class FCSIndirectTalonStateData : public FCSTalonStateData 00199 { 00200 public: 00202 friend class FCSIndirectTalonStateWithLocations; 00203 00205 FCSIndirectTalonStateData(); 00206 00208 virtual ~FCSIndirectTalonStateData(); 00209 00213 virtual void Copy(FCSTalonStateData* Data); 00214 00218 virtual int Compare(const FCSTalonStateData* TalonData); 00219 00224 FCSCard* GetTalon(int Position); 00225 00227 void KlondikeTalonQueueToStack(); 00228 00232 FCSCard* GetKlondikeTalonTopCard(); 00233 00234 protected: 00236 FCSIndirectCard* m_Talon; 00237 }; 00238 00240 class FCSIndirectTalonStateWithLocations : public FCSIndirectStateWithLocations<FCSTalonStateWithLocations> 00241 { 00242 public: 00244 FCSIndirectTalonStateWithLocations(); 00245 00247 virtual ~FCSIndirectTalonStateWithLocations(); 00248 00252 virtual void Copy(FCSStateWithLocations* State); 00253 00255 virtual void Initialize(int NumberOfStacks); 00256 00258 virtual void CleanState(); 00259 00263 void CacheTalonStacks(FCInternalHash<FCSTalonStateData, void>* TalonHash); 00264 00268 void CreateTalons(int NumberOfTalons); 00269 00273 FCSTalonStateData* GetTalonData(); 00274 00276 void DecrementKlondikeTalonStack(); 00277 00278 protected: 00280 FCSIndirectTalonStateData* m_TalonData; 00281 }; 00282 00283 00284 #endif