Package jadex.bdiv3.examples.puzzle
Class SokratesAgent
- java.lang.Object
- 
- jadex.bdiv3.examples.puzzle.SokratesAgent
 
- 
- Direct Known Subclasses:
- BenchmarkAgent
 
 public class SokratesAgent extends java.lang.ObjectPuzzle agent tries to solve a solitair board game by recursiveky applying means-end-reasoning.
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description classSokratesAgent.MoveGoalThe goal to make moves until the board reaches a solution.classSokratesAgent.MovePlanPlan to make a move.
 - 
Field SummaryFields Modifier and Type Field Description protected IBoardboardThe puzzle board.protected longdelayThe delay between two moves (in milliseconds).protected intdepthThe depth of the current move.protected java.lang.StringstrategyThe strategy (none=choose the first applicable, long=prefer jump moves, same_long=prefer long moves of same color, alter_long=prefer long move of alternate color).protected inttriescntThe number of tried moves.
 - 
Constructor SummaryConstructors Constructor Description SokratesAgent()
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description IFuture<java.lang.Void>body(IInternalAccess agent)Setup the gui and start playing.protected voidcreateGui(IInternalAccess agent)Create the GUI (if any).protected voidprint(java.lang.String text, int indent)Print out an indented string.
 
- 
- 
- 
Field Detail- 
boardprotected IBoard board The puzzle board.
 - 
triescntprotected int triescnt The number of tried moves.
 - 
depthprotected int depth The depth of the current move.
 - 
delayprotected long delay The delay between two moves (in milliseconds).
 - 
strategyprotected java.lang.String strategy The strategy (none=choose the first applicable, long=prefer jump moves, same_long=prefer long moves of same color, alter_long=prefer long move of alternate color).
 
- 
 - 
Method Detail- 
bodypublic IFuture<java.lang.Void> body(IInternalAccess agent) Setup the gui and start playing.
 - 
createGuiprotected void createGui(IInternalAccess agent) Create the GUI (if any).
 - 
printprotected void print(java.lang.String text, int indent)Print out an indented string.- Parameters:
- text- The text.
- indent- The number of cols to indent.
 
 
- 
 
-