Blackjack

com.amoebacode.blackjack.command
Class GameCommand

java.lang.Object
  |
  +--com.amoebacode.blackjack.command.GameCommand
All Implemented Interfaces:
ICommand
Direct Known Subclasses:
DealCommand, LowerBetCommand, RaiseBetCommand, ShuffleCommand

abstract class GameCommand
extends java.lang.Object
implements ICommand

GameCommand is the base class for all game commands.

Version:
0.9
Author:
Jason Gurney

Field Summary
private  IGame game
          The game target for this command
 
Constructor Summary
protected GameCommand(IGame game)
          Default protected constructor.
 
Method Summary
abstract  void execute()
          Executes this game command.
protected  IGame getGame()
          Returns the game target for this command.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

game

private IGame game
The game target for this command
Constructor Detail

GameCommand

protected GameCommand(IGame game)
Default protected constructor.
Parameters:
game - the IGame target for this command
Method Detail

execute

public abstract void execute()
Executes this game command.
Specified by:
execute in interface ICommand

getGame

protected IGame getGame()
Returns the game target for this command.
Returns:
this command's IGame target

Blackjack

Copyright © 2002 amoebacode.com.