Othello 1.0

edu.drexel.cs.ai.othello
Class HumanOthelloPlayer

java.lang.Object
  extended by edu.drexel.cs.ai.othello.OthelloPlayer
      extended by edu.drexel.cs.ai.othello.HumanOthelloPlayer

public final class HumanOthelloPlayer
extends OthelloPlayer

An interface for having a human play othello through the user interface.

Author:
Evan A. Sultanik

Constructor Summary
HumanOthelloPlayer(java.lang.String name)
          Creates a new agent that plays according to human input.
 
Method Summary
 Square getMove(GameState currentState, java.util.Date deadline)
          Returns the next move as input by the human from the UI.
 void handleUIInput(Square square)
          Callback function for receiving the next move from the UI.
 
Methods inherited from class edu.drexel.cs.ai.othello.OthelloPlayer
getMillisUntilDeadline, getName, log, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

HumanOthelloPlayer

public HumanOthelloPlayer(java.lang.String name)
Creates a new agent that plays according to human input.

Method Detail

handleUIInput

public void handleUIInput(Square square)
Callback function for receiving the next move from the UI.


getMove

public Square getMove(GameState currentState,
                      java.util.Date deadline)
Returns the next move as input by the human from the UI. Note that this function will block until the UI makes a call to handleUIInput(Square) with the next move. Also, the HumanOthelloPlayer agent will always have an infinite deadline.

Specified by:
getMove in class OthelloPlayer

Othello 1.0

Copyright 2006–2007 Evan A. Sultanik