libsgfc++ 2.0.1
A C++ library that uses SGFC to read and write SGF (Smart Game Format) data.
|
The SgfcOptions class is used to capture a snapshot of the option values in an SGFCOptions struct, and to reconfigure an SGFCOptions struct with those captured values at a later time. More...
#include <SgfcOptions.h>
Public Member Functions | |
SgfcOptions () | |
Initializes a newly constructed SgfcOptions object. The object holds default option values. | |
virtual | ~SgfcOptions () |
Destroys and cleans up the SgfcOptions object. | |
void | CaptureOptions (const SGFCOptions *sourceOptions) |
Captures a snapshot of the option values in sourceOptions. | |
void | RestoreOptions (SGFCOptions *targetOptions) const |
Reconfigures targetOptions with the option values that the SgfcOption object currently holds. | |
The SgfcOptions class is used to capture a snapshot of the option values in an SGFCOptions struct, and to reconfigure an SGFCOptions struct with those captured values at a later time.
Some notes about the internal workings of SGFC:
LibSgfcPlusPlus::SgfcOptions::SgfcOptions | ( | ) |
Initializes a newly constructed SgfcOptions object. The object holds default option values.
std::runtime_error | Is thrown if SGFC fails to allocate memory. |
void LibSgfcPlusPlus::SgfcOptions::RestoreOptions | ( | SGFCOptions * | targetOptions | ) | const |
Reconfigures targetOptions with the option values that the SgfcOption object currently holds.
If CaptureOptions() has never been invoked before, this applies default option values to targetOptions.