00001 //---------------------------------------------------------------------------- 00002 /** @file DfpnCommands.hpp 00003 */ 00004 //---------------------------------------------------------------------------- 00005 00006 #ifndef DFPNCOMMANDS_HPP 00007 #define DFPNCOMMANDS_HPP 00008 00009 #include "Game.hpp" 00010 #include "HexBoard.hpp" 00011 #include "HexHtpEngine.hpp" 00012 #include "HexEnvironment.hpp" 00013 #include "SolverDB.hpp" 00014 #include "DfpnSolver.hpp" 00015 00016 _BEGIN_BENZENE_NAMESPACE_ 00017 00018 //---------------------------------------------------------------------------- 00019 00020 /** Commands for building/inspecting virtual connections. */ 00021 class DfpnCommands 00022 { 00023 public: 00024 DfpnCommands(Game& game, HexEnvironment& env, DfpnSolver& solver, 00025 boost::scoped_ptr<DfpnHashTable>& hashTable, 00026 boost::scoped_ptr<DfpnDB>& db, 00027 DfpnStates& positions); 00028 00029 void Register(GtpEngine& engine); 00030 00031 private: 00032 Game& m_game; 00033 00034 HexEnvironment& m_env; 00035 00036 DfpnSolver& m_solver; 00037 00038 boost::scoped_ptr<DfpnHashTable>& m_tt; 00039 00040 boost::scoped_ptr<DfpnDB>& m_db; 00041 00042 DfpnStates& m_positions; 00043 00044 void Register(GtpEngine& engine, const std::string& command, 00045 GtpCallback<DfpnCommands>::Method method); 00046 00047 void CmdParam(HtpCommand& cmd); 00048 void CmdParamSolverDB(HtpCommand& cmd); 00049 void CmdSolveState(HtpCommand& cmd); 00050 void CmdFindWinning(HtpCommand& cmd); 00051 void CmdClearTT(HtpCommand& cmd); 00052 void CmdGetState(HtpCommand& cmd); 00053 void CmdGetBounds(HtpCommand& cmd); 00054 void CmdGetWork(HtpCommand& cmd); 00055 void CmdGetPV(HtpCommand& cmd); 00056 void CmdOpenDB(HtpCommand& cmd); 00057 void CmdCloseDB(HtpCommand& cmd); 00058 void CmdDBStat(HtpCommand& cmd); 00059 void CmdEvaluationInfo(HtpCommand& cmd); 00060 }; 00061 00062 //---------------------------------------------------------------------------- 00063 00064 _END_BENZENE_NAMESPACE_ 00065 00066 #endif // DFPNCOMMANDS_HPP