00001 /* threatmatePool.h 00002 */ 00003 #ifndef OSL_BRINKMATE_THREATMATEPOOL_H 00004 #define OSL_BRINKMATE_THREATMATEPOOL_H 00005 00006 #include "osl/move.h" 00007 #include "osl/stl/vector.h" 00008 #include "osl/misc/carray.h" 00009 00010 namespace osl 00011 { 00012 namespace brinkmate 00013 { 00017 class ThreatmatePool 00018 { 00019 public: 00020 typedef vector<Move> vector_t; 00021 private: 00022 CArray<vector_t,Position::SIZE> moves; 00023 public: 00024 ThreatmatePool(); 00025 ~ThreatmatePool(); 00026 00027 void add(Move, Position king); 00028 const vector_t& find(Position king) const { return moves[king.index()]; } 00029 00030 void show() const; 00031 }; 00032 } // namespace brinkmate 00033 } // namespace osl 00034 00035 #endif /* OSL_BRINKMATE_THREATMATEPOOL_H */ 00036 // ;;; Local Variables: 00037 // ;;; mode:c++ 00038 // ;;; c-basic-offset:2 00039 // ;;; End: