Index   Main   Namespaces   Classes   Hierarchy   Annotated   Files   Compound   Global   Pages  

GoGtpExtraCommands.h

Go to the documentation of this file.
00001 //----------------------------------------------------------------------------
00002 /** @file GoGtpExtraCommands.h */
00003 //----------------------------------------------------------------------------
00004 
00005 #ifndef GO_GTPEXTRACOMMANDS_H
00006 #define GO_GTPEXTRACOMMANDS_H
00007 
00008 #include <string>
00009 #include "GtpEngine.h"
00010 
00011 class GoBoard;
00012 class GoPlayer;
00013 
00014 //----------------------------------------------------------------------------
00015 
00016 /** Extra GTP commands to access functionality of the Go library.
00017     Contains commands that are mainly useful for debugging and testing
00018     the Go library and that not all Go GTP engines may want to register. */
00019 class GoGtpExtraCommands
00020 {
00021 public:
00022     /** Constructor.
00023         @param bd The game board. */
00024     GoGtpExtraCommands(const GoBoard& bd);
00025 
00026     void AddGoGuiAnalyzeCommands(GtpCommand& cmd);
00027 
00028     /** @page gogtpextracommands GoGtpExtraCommands Commands
00029         - @link CmdCfgDistance() @c go_distance @endlink
00030         - @link CmdLadder() @c go_ladder @endlink
00031         - @link CmdStaticLadder() @c go_static_ladder @endlink */
00032     /** @name Command Callbacks */
00033     // @{
00034     // The callback functions are documented in the cpp file
00035     void CmdCfgDistance(GtpCommand& cmd);
00036     void CmdLadder(GtpCommand& cmd);
00037     void CmdStaticLadder(GtpCommand& cmd);
00038     // @} // @name
00039 
00040     void Register(GtpEngine& engine);
00041 
00042 private:
00043     const GoBoard& m_bd;
00044 
00045     void Register(GtpEngine& e, const std::string& command,
00046                   GtpCallback<GoGtpExtraCommands>::Method method);
00047 };
00048 
00049 //----------------------------------------------------------------------------
00050 
00051 #endif // GO_GTPEXTRACOMMANDS_H


Sun Mar 13 2011 Doxygen 1.7.1