00001 //---------------------------------------------------------------------------- 00002 /** @file GoBoardRestorer.h 00003 */ 00004 //---------------------------------------------------------------------------- 00005 00006 #ifndef GO_BOARDRESTORER_H 00007 #define GO_BOARDRESTORER_H 00008 00009 #include "GoBoard.h" 00010 00011 //---------------------------------------------------------------------------- 00012 00013 /** Remembers the state of a board and restores it in its destructor. */ 00014 class GoBoardRestorer 00015 { 00016 public: 00017 GoBoardRestorer(GoBoard& bd); 00018 00019 ~GoBoardRestorer(); 00020 00021 private: 00022 typedef SgSList<GoPlayerMove,GO_MAX_NUM_MOVES> MoveList; 00023 00024 GoBoard& m_bd; 00025 00026 int m_size; 00027 00028 GoRules m_rules; 00029 00030 MoveList m_moves; 00031 }; 00032 00033 //---------------------------------------------------------------------------- 00034 00035 #endif // GO_BOARDRESTORER_H