Algorithm
Development Kit 1.0

algs.model.gametree
Interface IGameMove

All Known Implementing Classes:
Move, PlaceMark

public interface IGameMove

A valid move in the GameTree.

Since:
1.0
Version:
1.0, 6/15/08
Author:
George Heineman

Method Summary
 boolean execute(IGameState state)
          Execute the move on the game state.
 boolean isValid(IGameState state)
          Determine if move is valid in the game state.
 boolean undo(IGameState state)
          Undo the move on the game state.
 

Method Detail

execute

boolean execute(IGameState state)
Execute the move on the game state.

Parameters:
state - game tree state to be updated by this move

undo

boolean undo(IGameState state)
Undo the move on the game state.

Parameters:
state - game tree state to be undone one move

isValid

boolean isValid(IGameState state)
Determine if move is valid in the game state.

Parameters:
state - game tree state to be inspected by move

Algorithm Development Kit 1.0

This code supports the Algorithms in a Nutshell book, published by O'Reilly Media, Inc. in November 2008. Please visit the book web page to learn of any changes to the code repository or to record a potential defect.