edu.ou.mlfw
Interface Controllable<ACTION,STATE,CLIENT>

All Known Implementing Classes:
MancalaControllable, PacmanControllable

public interface Controllable<ACTION,STATE,CLIENT>

A Controllable is an element of a simulator that can be controlled by a client. At each timestep, a controllable must provide a non-empty set of actions that a client can select from to respond to the current state of the simulator. After providing this set, the controllable must accept and appropriately follow an action submitted to it, unless that action is not an element of the set of actions provided. The behavior upon receiving an illegal action is undefined. The simulator should be able to read a controllable's currently set action and update one or more simulator objects based on that action.


Method Summary
 void endAction(STATE state, CLIENT client)
           
 java.lang.String getName()
          Return this controllable's unique identifying name.
 Record getRecord()
          Return this controllable's statistic information.
 boolean isLegal(ACTION action)
          Indicates whether the given action is legal for the controllable.
 void startAction(STATE state, CLIENT client)
           
 

Method Detail

isLegal

boolean isLegal(ACTION action)
Indicates whether the given action is legal for the controllable.

Parameters:
action -
Returns:

startAction

void startAction(STATE state,
                 CLIENT client)

endAction

void endAction(STATE state,
               CLIENT client)

getName

java.lang.String getName()
Return this controllable's unique identifying name.

Returns:

getRecord

Record getRecord()
Return this controllable's statistic information.

Returns: