Coord Class Reference

#include <coord.h>


Detailed Description

Definition at line 32 of file coord.h.

Public Types

enum  Direction { VERTICAL, HORIZONTAL }
enum  coord_mode_t { COORD_MODE_COMPACT, COORD_MODE_LONG }

Public Member Functions

 Coord (int iRow=-1, int iCol=-1, Direction iDir=HORIZONTAL)
 Coord (const string &iStr)
virtual ~Coord ()
void setRow (int iRow)
void setCol (int iCol)
void setDir (Direction iDir)
int getRow () const
int getCol () const
Direction getDir () const
bool isValid () const
void operator= (const Coord &iOther)
void swap ()
void setFromString (const string &iStr)
string toString (coord_mode_t mode=COORD_MODE_COMPACT) const


Member Enumeration Documentation

enum Coord::coord_mode_t
 

Enumerator:
COORD_MODE_COMPACT 
COORD_MODE_LONG 

Definition at line 59 of file coord.h.

enum Coord::Direction
 

Enumerator:
VERTICAL 
HORIZONTAL 

Definition at line 36 of file coord.h.


Constructor & Destructor Documentation

Coord::Coord int  iRow = -1,
int  iCol = -1,
Direction  iDir = HORIZONTAL
 

Definition at line 33 of file coord.cpp.

Coord::Coord const string &  iStr  ) 
 

Definition at line 40 of file coord.cpp.

References setFromString().

virtual Coord::~Coord  )  [inline, virtual]
 

Definition at line 41 of file coord.h.


Member Function Documentation

int Coord::getCol  )  const [inline]
 

Definition at line 48 of file coord.h.

Referenced by Board::addRound(), BoardSearchEvalMove(), LeftPart(), Board::removeRound(), and Board::testRound().

Direction Coord::getDir  )  const [inline]
 

Definition at line 49 of file coord.h.

Referenced by Board::addRound(), BoardSearchEvalMove(), Board::checkRound(), Board::removeRound(), Board::testRound(), and toString().

int Coord::getRow  )  const [inline]
 

Definition at line 47 of file coord.h.

Referenced by Board::addRound(), BoardSearchEvalMove(), Board::removeRound(), and Board::testRound().

bool Coord::isValid  )  const
 

Definition at line 45 of file coord.cpp.

References BOARD_MAX, and BOARD_MIN.

Referenced by Game::checkPlayedWord(), and toString().

void Coord::operator= const Coord iOther  ) 
 

Definition at line 51 of file coord.cpp.

References m_col, m_dir, and m_row.

void Coord::setCol int  iCol  )  [inline]
 

Definition at line 45 of file coord.h.

Referenced by BoardSearchAux(), Round::init(), LeftPart(), Board::searchFirst(), and setFromString().

void Coord::setDir Direction  iDir  )  [inline]
 

Definition at line 46 of file coord.h.

Referenced by BoardSearchAux(), Round::init(), Board::searchFirst(), and setFromString().

void Coord::setFromString const string &  iStr  ) 
 

Definition at line 65 of file coord.cpp.

References HORIZONTAL, setCol(), setDir(), setRow(), and VERTICAL.

Referenced by Game::checkPlayedWord(), and Coord().

void Coord::setRow int  iRow  )  [inline]
 

Definition at line 44 of file coord.h.

Referenced by BoardSearchAux(), Round::init(), Board::searchFirst(), and setFromString().

void Coord::swap  ) 
 

Definition at line 58 of file coord.cpp.

Referenced by BoardSearchEvalMove().

string Coord::toString coord_mode_t  mode = COORD_MODE_COMPACT  )  const
 

Definition at line 88 of file coord.cpp.

References ASSERT, COORD_MODE_COMPACT, COORD_MODE_LONG, getDir(), HORIZONTAL, and isValid().

Referenced by searchResultLine(), and Round::toString().


The documentation for this class was generated from the following files:
Generated on Thu Dec 29 02:01:15 2005 for Eliot by  doxygen 1.4.5