All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
openingBookTracer.h
Go to the documentation of this file.
1 /* openingBookTracer.h
2  */
3 #ifndef _OPENINGBOOKTRACER_H
4 #define _OPENINGBOOKTRACER_H
5 
6 #include "osl/move.h"
7 
8 namespace osl
9 {
10  namespace game_playing
11  {
16  {
17  protected:
18  bool verbose;
19  public:
20  OpeningBookTracer() : verbose(false) {}
21  virtual ~OpeningBookTracer();
23  virtual OpeningBookTracer* clone() const = 0;
25  virtual void update(Move)=0;
30  virtual const Move selectMove() const=0;
31  virtual bool isOutOfBook() const=0;
35  virtual void popMove()=0;
36  bool isVerbose() const { return verbose; }
37  };
38 
42  class NullBook : public OpeningBookTracer
43  {
44  public:
45  ~NullBook();
47  {
48  return new NullBook();
49  }
50 
51  void update(Move);
52  const Move selectMove() const;
53  bool isOutOfBook() const;
54  void popMove();
55  };
56 
57  } // namespace game_playing
58 } // namespace osl
59 
60 #endif /* _OPENINGBOOKTRACER_H */
61 // ;;; Local Variables:
62 // ;;; mode:c++
63 // ;;; c-basic-offset:2
64 // ;;; End: