State Class Reference

abstract state. More...

#include <State.h>

Inherited by StateEnd, StateLoop, StateSettings, and StateStart.

Collaboration diagram for State:
Collaboration graph
[legend]

List of all members.

Public Member Functions

virtual void update ()
virtual void doPrint ()=0
virtual void doGetKey ()=0
 State ()
virtual ~State ()

Protected Member Functions

virtual void clearConsole ()

Static Protected Attributes

static GameContextgameContext = 0

Detailed Description

abstract state.

Abstract state of state pattern. Defined all states.

Definition at line 9 of file State.h.


Constructor & Destructor Documentation

State::State (  )  [inline]

Definition at line 20 of file State.h.

virtual State::~State (  )  [inline, virtual]

Definition at line 21 of file State.h.


Member Function Documentation

virtual void State::clearConsole (  )  [inline, protected, virtual]

Clear Windows console. You can override.

Definition at line 27 of file State.h.

Here is the caller graph for this function:

virtual void State::doGetKey (  )  [pure virtual]

Use this Methode to get an input information. You have to override.

Implemented in StateEnd, StateLoop, StateSettings, and StateStart.

Here is the caller graph for this function:

virtual void State::doPrint (  )  [pure virtual]

Use this Methode to print state information. You have to override.

Implemented in StateEnd, StateLoop, StateSettings, and StateStart.

Here is the caller graph for this function:

virtual void State::update (  )  [inline, virtual]

Use this Methode to update the state before doPrint() or doGetKey() is called. You can override. Default implementation calls clearConsole().

Reimplemented in StateLoop.

Definition at line 13 of file State.h.

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

GameContext * State::gameContext = 0 [static, protected]

Represent the context and allow concrete stats access to context data. Shared with all states.

Definition at line 25 of file State.h.


The documentation for this class was generated from the following files:

Generated on Sat Oct 10 03:29:20 2009 for Hangman by  doxygen 1.6.1