analyzer.h Source File

- Main Page
- Namespaces
- Classes
- Files

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
analyzer.h
Go to the documentation of this file.
1 /* analyzer.h
2 */
3 #ifndef OSL_ANNOTATE_ANALYZER_H
4 #define OSL_ANNOTATE_ANALYZER_H
5
6 #include "osl/annotate/analysesResult.h"
7 #include "osl/state/numEffectState.h"
8 #include "osl/stl/vector.h"
9
10 namespace osl
11 {
12 namespace annotate
13 {
14 class Analyzer
15 {
16 public:
17 virtual ~Analyzer();
18 virtual void match(AnalysesResult&,
19 const NumEffectState& src, const vector<Move>& moves,
20 int last_move)=0;
21
22 static Trivalent isCheckmate(NumEffectState& state, Move& best_move, bool attack=true,
23 size_t *node_count=0);
24 };
26 class RepetitionAnalyzer : public Analyzer
27 {
28 public:
29 void match(AnalysesResult&,
30 const NumEffectState& src, const vector<Move>& moves,
31 int last_move);
32 };
34 class CheckmateAnalyzer : public Analyzer
35 {
36 public:
37 void match(AnalysesResult&,
38 const NumEffectState& src, const vector<Move>& moves,
39 int last_move);
40 };
42 class CheckmateWin : public Analyzer
43 {
44 public:
45 void match(AnalysesResult&,
46 const NumEffectState& src, const vector<Move>& moves,
47 int last_move);
48 };
49 class EscapeFromCheck : public Analyzer
50 {
51 public:
52 void match(AnalysesResult&,
53 const NumEffectState& src, const vector<Move>& moves,
54 int last_move);
55 static bool matchMain(const NumEffectState& src, const vector<Move>& moves,
56 int last_move);
57 };
58 class ThreatmateAnalyzer : public Analyzer
59 {
60 public:
61 void match(AnalysesResult&,
62 const NumEffectState& src, const vector<Move>& moves,
63 int last_move);
64 };
65 class CheckmateForCapture : public Analyzer
66 {
67 public:
68 void match(AnalysesResult&,
69 const NumEffectState& src, const vector<Move>& moves,
70 int last_move);
71 };
72 class CheckmateForEscape : public Analyzer
73 {
74 public:
75 void match(AnalysesResult&,
76 const NumEffectState& src, const vector<Move>& moves,
77 int last_move);
78 };
79 class ThreatmateIfMorePieces : public Analyzer
80 {
81 public:
82 void match(AnalysesResult&,
83 const NumEffectState& src, const vector<Move>& moves,
84 int last_move);
85 static bool suitable(const NumEffectState& state, Piece p);
86 };
87 class Vision3 : public Analyzer
88 {
89 public:
90 void match(AnalysesResult&,
91 const NumEffectState& src, const vector<Move>& moves,
92 int last_move);
93 };
94 }
95 }
96
97 #endif /* OSL_ANNOTATE_ANALYZER_H */
98 // ;;; Local Variables:
99 // ;;; mode:c++
100 // ;;; c-basic-offset:2
101 // ;;; coding:utf-8
102 // ;;; End: