Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members

AFreecellGameBoard Class Reference

The abstract, parent class for all game board generation.

#include <AFreecellGameBoard.h>

Inheritance diagram for AFreecellGameBoard:

AisleRiotGameBoard APysolFreecellGameBoard MicrosoftFreecellGameBoard AisleRiotBeleagueredCastleGameBoard AisleRiotEightOffGameBoard AisleRiotFreecellGameBoard AisleRiotKlondikeGameBoard AisleRiotSeahavenTowersGameBoard PysolBakersDozenGameBoard PysolBeleagueredCastleGameBoard PysolCitadelGameBoard PysolDerKatzenschwantzGameBoard PysolEightOffGameBoard PysolFanGameBoard PysolForecellGameBoard PysolFreecellGameBoard PysolKlondikeGameBoard PysolSeahavenTowersGameBoard PysolSimpleSimonGameBoard PysolSmallHarpGameBoard PysolWhiteheadGameBoard PysolYukonGameBoard GnomeFreecellGameBoard List of all members.

Public Member Functions

virtual ~AFreecellGameBoard ()
 Destructor.
virtual void Shuffle (int Seed)=0
 Shuffles the deck of cards.
virtual void Deal (char *GameBoard)=0
 Deal the cards of a game.
virtual int GetGameBoardSize ()=0
 The size of a string needed to store the generated board output.

Protected Member Functions

 AFreecellGameBoard (bool Display10AsT)
 Constructor.
 AFreecellGameBoard ()
 Constructor.
virtual int GetNumberOfCardsInDeck ()
 Number of cards used in a game.
virtual char * CardToString (char *String, char Card, bool AppendWhiteSpace, bool FlipCondition=false)
 Converts a char Card into a string.

Protected Attributes

char * m_Deck
 The deck of cards for the game.
bool m_Display10AsT
 Display "10" as a "T".

Detailed Description

Definition at line 93 of file AFreecellGameBoard.h.


Member Function Documentation

char * AFreecellGameBoard::CardToString char *  String,
char  Card,
bool  AppendWhiteSpace,
bool  FlipCondition = false
[protected, virtual]
 

Parameters:
String is the string created from the card
Card is the card to be converted
AppendWhiteSpace determines whether or not to add a space in the string after the card
FlipCondition is whether or not the card is visible on a deal
Returns:
A pointer to the string

Reimplemented in APysolFreecellGameBoard.

Definition at line 334 of file AFreecellGameBoard.cpp.

References GetSuit, GetValue, and m_Display10AsT.

Referenced by AisleRiotBeleagueredCastleGameBoard::Deal(), AisleRiotSeahavenTowersGameBoard::Deal(), AisleRiotEightOffGameBoard::Deal(), AisleRiotKlondikeGameBoard::Deal(), AisleRiotFreecellGameBoard::Deal(), and MicrosoftFreecellGameBoard::Deal().

virtual void AFreecellGameBoard::Deal char *  GameBoard  )  [pure virtual]
 

Parameters:
GameBoard is the string the output is put into

Implemented in MicrosoftFreecellGameBoard, AisleRiotFreecellGameBoard, AisleRiotKlondikeGameBoard, AisleRiotEightOffGameBoard, AisleRiotSeahavenTowersGameBoard, AisleRiotBeleagueredCastleGameBoard, PysolFreecellGameBoard, PysolDerKatzenschwantzGameBoard, PysolDieSchlangeGameBoard, PysolForecellGameBoard, PysolEightOffGameBoard, PysolSeahavenTowersGameBoard, PysolBakersDozenGameBoard, PysolGypsyGameBoard, PysolKlondikeGameBoard, PysolWhiteheadGameBoard, PysolSmallHarpGameBoard, PysolSimpleSimonGameBoard, PysolYukonGameBoard, PysolBeleagueredCastleGameBoard, PysolCitadelGameBoard, and PysolFanGameBoard.

Referenced by main(), and TestEachGame().

virtual int AFreecellGameBoard::GetGameBoardSize  )  [pure virtual]
 

Returns:
Size of string needed

Implemented in MicrosoftFreecellGameBoard, AisleRiotGameBoard, AisleRiotFreecellGameBoard, AisleRiotKlondikeGameBoard, AisleRiotEightOffGameBoard, AisleRiotSeahavenTowersGameBoard, AisleRiotBeleagueredCastleGameBoard, APysolFreecellGameBoard, PysolFreecellGameBoard, PysolDerKatzenschwantzGameBoard, PysolDieSchlangeGameBoard, PysolForecellGameBoard, PysolEightOffGameBoard, PysolSeahavenTowersGameBoard, PysolBakersDozenGameBoard, PysolGypsyGameBoard, PysolKlondikeGameBoard, PysolWhiteheadGameBoard, PysolSmallHarpGameBoard, PysolSimpleSimonGameBoard, PysolYukonGameBoard, PysolBeleagueredCastleGameBoard, PysolCitadelGameBoard, and PysolFanGameBoard.

Referenced by main().

int AFreecellGameBoard::GetNumberOfCardsInDeck  )  [protected, virtual]
 

Returns:
The number of cards used in a game

Reimplemented in AisleRiotBeleagueredCastleGameBoard, and PysolDerKatzenschwantzGameBoard.

Definition at line 328 of file AFreecellGameBoard.cpp.

Referenced by AFreecellGameBoard(), PysolFanGameBoard::Deal(), PysolCitadelGameBoard::Deal(), PysolBeleagueredCastleGameBoard::Deal(), PysolBakersDozenGameBoard::Deal(), PysolSeahavenTowersGameBoard::Deal(), PysolEightOffGameBoard::Deal(), PysolForecellGameBoard::Deal(), PysolFreecellGameBoard::Deal(), AisleRiotSeahavenTowersGameBoard::Deal(), AisleRiotEightOffGameBoard::Deal(), AisleRiotKlondikeGameBoard::Deal(), AisleRiotFreecellGameBoard::Deal(), MicrosoftFreecellGameBoard::Deal(), APysolFreecellGameBoard::Shuffle(), AisleRiotGameBoard::Shuffle(), GnomeFreecellGameBoard::Shuffle(), and MicrosoftFreecellGameBoard::Shuffle().

virtual void AFreecellGameBoard::Shuffle int  Seed  )  [pure virtual]
 

Parameters:
Seed is the random number seed used in the shuffle

Implemented in MicrosoftFreecellGameBoard, GnomeFreecellGameBoard, AisleRiotGameBoard, and APysolFreecellGameBoard.

Referenced by main(), and TestEachGame().


The documentation for this class was generated from the following files:
Generated on Sat Nov 5 11:20:16 2005 for Cpp Freecell Solver by  doxygen 1.4.4