Used to restore ToPlay to its current value in an exception-safe way. More...
#include <GoBoardUtil.h>
Public Member Functions | |
GoRestoreToPlay (GoBoard &board) | |
~GoRestoreToPlay () | |
Private Member Functions | |
GoRestoreToPlay (const GoRestoreToPlay &) | |
Not implemented. | |
GoRestoreToPlay & | operator= (const GoRestoreToPlay &) |
Not implemented. | |
Private Attributes | |
GoBoard & | m_board |
SgBlackWhite | m_oldToPlay |
Used to restore ToPlay to its current value in an exception-safe way.
To use it, just declare a RestoreToPlay variable on the stack for the desired scope.
Definition at line 913 of file GoBoardUtil.h.
GoRestoreToPlay::GoRestoreToPlay | ( | GoBoard & | board | ) |
Definition at line 916 of file GoBoardUtil.h.
GoRestoreToPlay::~GoRestoreToPlay | ( | ) |
Definition at line 921 of file GoBoardUtil.h.
References m_board, m_oldToPlay, and GoBoard::SetToPlay().
GoRestoreToPlay::GoRestoreToPlay | ( | const GoRestoreToPlay & | ) | [private] |
Not implemented.
GoRestoreToPlay& GoRestoreToPlay::operator= | ( | const GoRestoreToPlay & | ) | [private] |
Not implemented.
GoBoard& GoRestoreToPlay::m_board [private] |
Definition at line 927 of file GoBoardUtil.h.
Referenced by ~GoRestoreToPlay().
SgBlackWhite GoRestoreToPlay::m_oldToPlay [private] |
Definition at line 929 of file GoBoardUtil.h.
Referenced by ~GoRestoreToPlay().