|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.dartra.standard.visitor.LastCompletedGameVisitor
Visitor that searches for the last completed game (or set) at every level of the game-match tree. A completed game is a game where the winner has been determined.
| Constructor Summary | |
LastCompletedGameVisitor()
|
|
| Method Summary | |
Game |
getLastCompletedGame(int level)
Returns the last completed game at given level of the game-match tree. |
int |
getMaxLevel()
Returns the level number for the game-match tree. |
void |
visitGame(Game game)
Process game data. |
void |
visitMatch(Match match)
Process match data. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public LastCompletedGameVisitor()
| Method Detail |
public void visitGame(Game game)
GameVisitorProcess game data.
visitGame in interface GameVisitorpublic void visitMatch(Match match)
GameVisitorProcess match data.
visitMatch in interface GameVisitorpublic Game getLastCompletedGame(int level)
Returns the last completed game at given level of the game-match tree. When no corresponding game can be found, null is returned.
public int getMaxLevel()
Returns the level number for the game-match tree. For instance, for a game/set/match system, this would be 2.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||