eliot-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Eliot-dev] eliot/game history.h


From: eliot-dev
Subject: [Eliot-dev] eliot/game history.h
Date: Mon, 02 Jan 2006 19:05:37 +0000

CVSROOT:        /sources/eliot
Module name:    eliot
Branch:         
Changes by:     Olivier Teulière <address@hidden>      06/01/02 19:05:37

Modified files:
        game           : history.h 

Log message:
        Use forward declarations to reduce dependencies

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/eliot/eliot/game/history.h.diff?tr1=1.9&tr2=1.10&r1=text&r2=text

Patches:
Index: eliot/game/history.h
diff -u eliot/game/history.h:1.9 eliot/game/history.h:1.10
--- eliot/game/history.h:1.9    Sun Jan  1 19:49:35 2006
+++ eliot/game/history.h        Mon Jan  2 19:05:37 2006
@@ -27,10 +27,16 @@
 #ifndef _HISTORY_H
 #define _HISTORY_H
 
+#include <string>
 #include <vector>
-#include "pldrack.h"
-#include "round.h"
-#include "turn.h"
+
+using std::string;
+using std::vector;
+
+class Round;
+class Turn;
+class PlayedRack;
+
 
 /**
  * History stores all the turns that have been played
@@ -39,18 +45,19 @@
  *  - one for each of the players
  *
  * A History is never void (getSize() can be used as the is the current turn
- * number for the complete game history). 
+ * number for the complete game history).
  *
  * History starts at zero.
  *
  * The top of the history is an empty
  * Turn until it has been filled and game is up to a new round.
- * 
- * getCurrentRack() can/should be used to store the current played rack. 
+ *
+ * getCurrentRack() can/should be used to store the current played rack.
  * setCurrentRack must be called whenever the current played rack is
  * modified.
- * 
- * History owns the turns that it stores. Do not delete a turn referenced by 
History
+ *
+ * History owns the turns that it stores. Do not delete a turn referenced
+ * by History
  */
 
 class History
@@ -85,7 +92,7 @@
     string toString() const;
 
  private:
-    vector < Turn* > m_history;
+    vector<Turn*> m_history;
 };
 
 #endif




reply via email to

[Prev in Thread] Current Thread [Next in Thread]