edu.ou.pacman
Class PacmanControllable

java.lang.Object
  extended by edu.ou.pacman.PacmanControllable
All Implemented Interfaces:
Controllable<Direction,ImmutablePacmanState,AbstractPacmanClient>

public class PacmanControllable
extends java.lang.Object
implements Controllable<Direction,ImmutablePacmanState,AbstractPacmanClient>

Author:
zack

Constructor Summary
PacmanControllable(PacmanCharacter character, GameBoard board)
           
 
Method Summary
 void endAction(ImmutablePacmanState state, AbstractPacmanClient client)
           
 java.lang.String getName()
          Return this controllable's unique identifying name.
 Record getRecord()
          Return this controllable's statistic information.
 boolean isLegal(Direction action)
          Indicates whether the given action is legal for the controllable.
 void startAction(ImmutablePacmanState state, AbstractPacmanClient client)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PacmanControllable

public PacmanControllable(PacmanCharacter character,
                          GameBoard board)
Method Detail

isLegal

public boolean isLegal(Direction action)
Description copied from interface: Controllable
Indicates whether the given action is legal for the controllable.

Specified by:
isLegal in interface Controllable<Direction,ImmutablePacmanState,AbstractPacmanClient>
Returns:

getName

public java.lang.String getName()
Description copied from interface: Controllable
Return this controllable's unique identifying name.

Specified by:
getName in interface Controllable<Direction,ImmutablePacmanState,AbstractPacmanClient>
Returns:

getRecord

public Record getRecord()
Description copied from interface: Controllable
Return this controllable's statistic information.

Specified by:
getRecord in interface Controllable<Direction,ImmutablePacmanState,AbstractPacmanClient>
Returns:

startAction

public void startAction(ImmutablePacmanState state,
                        AbstractPacmanClient client)
Specified by:
startAction in interface Controllable<Direction,ImmutablePacmanState,AbstractPacmanClient>

endAction

public void endAction(ImmutablePacmanState state,
                      AbstractPacmanClient client)
Specified by:
endAction in interface Controllable<Direction,ImmutablePacmanState,AbstractPacmanClient>