game_io.h

Go to the documentation of this file.
00001 /*****************************************************************************
00002  * Copyright (C) 1999-2005 Eliot
00003  * Authors: Antoine Fraboulet <antoine.fraboulet@free.fr>
00004  *          Olivier Teuliere  <ipkiss@via.ecp.fr>
00005  *
00006  * This program is free software; you can redistribute it and/or modify
00007  * it under the terms of the GNU General Public License as published by
00008  * the Free Software Foundation; either version 2 of the License, or
00009  * (at your option) any later version.
00010  *
00011  * This program is distributed in the hope that it will be useful,
00012  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014  * GNU General Public License for more details.
00015  *
00016  * You should have received a copy of the GNU General Public License
00017  * along with this program; if not, write to the Free Software
00018  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
00019  *****************************************************************************/
00020 
00021 #ifndef _GAME_IO_H_
00022 #define _GAME_IO_H_
00023 
00024 #include <iostream>
00025 
00026 class Game;
00027 class Training;
00028 
00029 using std::ostream;
00030 
00031 
00032 /**
00033  * This class offers methods to display some information relative to a game
00034  * object. It is currently used by the 'eliottxt' interface, but is also useful
00035  * for debugging purposes. Feel free to add other printing methods that you may
00036  * need...
00037  *
00038  * TODO: Maybe we could also use this class as a basis for non-regression tests?
00039  */
00040 class GameIO
00041 {
00042 public:
00043     static void printBoard(ostream &out, const Game &iGame);
00044     static void printBoardJoker(ostream &out, const Game &iGame);
00045     static void printBoardMultipliers(ostream &out, const Game &iGame);
00046     static void printBoardMultipliers2(ostream &out, const Game &iGame);
00047     static void printNonPlayed(ostream &out, const Game &iGame);
00048     static void printPlayedRack(ostream &out, const Game &iGame, int n);
00049     static void printAllRacks(ostream &out, const Game &iGame);
00050     static void printSearchResults(ostream &out, const Training &iGame, int);
00051     static void printPoints(ostream &out, const Game &iGame);
00052     static void printAllPoints(ostream &out, const Game &iGame);
00053 
00054 private:
00055     /// This class is a toolbox, and should not be instanciated
00056     GameIO();
00057 };
00058 
00059 #endif
00060 

Generated on Thu Dec 29 02:01:14 2005 for Eliot by  doxygen 1.4.5