openingBookTracer.h
Go to the documentation of this file.
00001 /* openingBookTracer.h
00002  */
00003 #ifndef _OPENINGBOOKTRACER_H
00004 #define _OPENINGBOOKTRACER_H
00005 
00006 #include "osl/move.h"
00007 
00008 namespace osl
00009 {
00010   namespace game_playing
00011   {
00015     class OpeningBookTracer
00016     {
00017     protected:
00018       bool verbose;
00019     public:
00020       OpeningBookTracer() : verbose(false) {}
00021       virtual ~OpeningBookTracer();
00023       virtual OpeningBookTracer* clone() const = 0;
00025       virtual void update(Move)=0;
00030       virtual const Move selectMove() const=0;
00031       virtual bool isOutOfBook() const=0;
00035       virtual void popMove()=0;
00036       bool isVerbose() const { return verbose; }
00037     };
00038 
00042     class NullBook : public OpeningBookTracer
00043     {
00044     public:
00045       ~NullBook();
00046       OpeningBookTracer* clone() const 
00047       {
00048         return new NullBook();
00049       }
00050       
00051       void update(Move);
00052       const Move selectMove() const;
00053       bool isOutOfBook() const;
00054       void popMove();
00055     };
00056     
00057   } // namespace game_playing
00058 } // namespace osl
00059 
00060 #endif /* _OPENINGBOOKTRACER_H */
00061 // ;;; Local Variables:
00062 // ;;; mode:c++
00063 // ;;; c-basic-offset:2
00064 // ;;; End:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines