|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.moyoman.module.Module | +--org.moyoman.module.movegenerator.simplemovegenerator.SimpleMoveGenerator
This module implements the MoveGenerator interface. It is responsible for taking the output of the other modules, and producing the next move.
Field Summary | |
private static DebugType[] |
dt
The debug types that this module supports. |
(package private) boolean |
isGenerated
|
private static int |
MAX_MOVES
The total number of rated moves that getMoves() will return. |
private MoveDescriptor |
move
The move to be made. |
private ModuleType[] |
mt
The modules that this module requires. |
private RatedMove[] |
ratedMoves
The moves that are rated by this module. |
Fields inherited from class org.moyoman.module.Module |
|
Constructor Summary | |
SimpleMoveGenerator(GameId id,
ModuleName name)
Create the SimpleMoveGenerator object. |
Method Summary | |
Object |
clone()
Override the Object.clone() method. |
void |
generateMove(Module[] modules)
Generate the rated moves, and the next move. |
Debug[] |
getDebugInformation(DebugType[] types)
Get the debug information for this module. |
DebugType[] |
getDebugTypes()
Get the debug types that this module supports. |
MoveDescriptor |
getGeneratedMove()
Get the generated move. |
RatedMove[] |
getMoves()
Get the rated moves for this module. |
ModuleType[] |
getRequiredModuleList()
Get the module types that this module requires. |
void |
makeMove(Move mv,
Module[] modules)
Make the move. |
Methods inherited from class org.moyoman.module.Module |
checkTime, create, createHelper, debug, error, error, fatal, fatal, getAllHelpers, getHelper, getId, getKomi, getModule, getModuleName, getScheduler, information, setTime, warning, warning |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.moyoman.module.ModuleInterface |
getScheduler |
Field Detail |
private static final int MAX_MOVES
private static DebugType[] dt
private ModuleType[] mt
private MoveDescriptor move
private RatedMove[] ratedMoves
boolean isGenerated
Constructor Detail |
public SimpleMoveGenerator(GameId id, ModuleName name) throws InternalErrorException
id
- The id of the game.name
- The name of this module.
InternalErrorException
- Thrown if the operation fails for any reason.Method Detail |
public MoveDescriptor getGeneratedMove()
getGeneratedMove
in interface MoveGenerator
public void generateMove(Module[] modules)
generateMove
in class Module
modules
- The modules that this module uses.public Debug[] getDebugInformation(DebugType[] types)
getDebugInformation
in class Module
types
- The debug types which the caller supports.
public DebugType[] getDebugTypes()
getDebugTypes
in class Module
public RatedMove[] getMoves()
getMoves
in interface ModuleInterface
getMoves
in class Module
public ModuleType[] getRequiredModuleList()
getRequiredModuleList
in class Module
public void makeMove(Move mv, Module[] modules)
makeMove
in class Module
mv
- The last move made.modules
- The modules that this module requires.public Object clone()
clone
in interface ModuleInterface
clone
in class Module
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |