|
meerkat | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectpoker.GameRecord
public class GameRecord
Logs a GameInfo object to disk as our standard formatted game log string.
Constructor Summary | |
---|---|
GameRecord(GameInfo gi)
|
|
GameRecord(java.lang.String gameRecString)
Creates a new GameRecord out of a game record log string. |
Method Summary | |
---|---|
java.lang.String |
boardString()
|
java.lang.String |
cardString(java.lang.String str)
|
java.lang.String |
generateTranscript()
Given a GameRecord, generate a text transcript of the hand |
int |
getAction(int pi,
int n)
|
Hand |
getBoard()
Returns the board. |
int |
getButton()
Returns the position of the button. |
Hand[] |
getCards()
Returns each player's hole cards. |
int |
getID()
Returns the id of the game. |
java.lang.String[] |
getNames()
Returns each player's name. |
int |
getNumActionType(int pos,
char act,
int stageFilter)
Get the number of an action made by this player |
int |
getNumPlayers()
Returns the number of players. |
int |
getNumWinners()
|
int |
getPlayedStage(int pos)
Get the stage of the game this player went to. |
int |
getPlayerIndex(java.lang.String name)
|
int |
getPlayerPosition(java.lang.String name)
Find the position of the given player by name |
java.lang.String |
getSequence()
Returns the betting sequence. |
double |
getValue(int pos)
|
double[] |
getValues()
Returns each player's value. |
java.lang.String |
toString()
|
java.lang.String |
toStringFull()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public GameRecord(GameInfo gi)
public GameRecord(java.lang.String gameRecString)
Method Detail |
---|
public java.lang.String toStringFull()
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String cardString(java.lang.String str)
public java.lang.String boardString()
public int getPlayerIndex(java.lang.String name)
public int getAction(int pi, int n)
public int getID()
public int getNumPlayers()
public int getButton()
public Hand getBoard()
public java.lang.String getSequence()
public java.lang.String[] getNames()
public int getPlayerPosition(java.lang.String name)
name
- the name of the player
public Hand[] getCards()
public double[] getValues()
public double getValue(int pos)
public int getNumWinners()
public int getPlayedStage(int pos)
pos
- the position of the player
public int getNumActionType(int pos, char act, int stageFilter)
pos
- the position of the playeract
- the action character to countstage
- count only for this stage (-1 is all stages)
public java.lang.String generateTranscript()
|
meerkat | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |