com.asdf.plugins.pokergames
Class StatisticsPlayer
java.lang.Object
com.asdf.plugins.pokergames.StatisticsPlayer
public class StatisticsPlayer
- extends java.lang.Object
Class containing player statistics.
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
StatisticsPlayer
public StatisticsPlayer(PlayerInfo player)
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object
getCards
public java.lang.String[] getCards()
- Returns:
- the cards
setCards
public void setCards(java.lang.String[] cards)
- Parameters:
cards
- the cards to set
getFlop
public java.lang.String getFlop()
- Returns:
- the flop
appendFlop
public void appendFlop(java.lang.String flop)
- Parameters:
flop
- the flop to set
getMoneyIn
public double getMoneyIn()
- Returns:
- the moneyIn
setMoneyIn
public void setMoneyIn(double moneyIn)
- Parameters:
moneyIn
- the moneyIn to set
getPreflop
public java.lang.String getPreflop()
- Returns:
- the preflop
appendPreflop
public void appendPreflop(java.lang.String preflop)
- Parameters:
preflop
- the preflop to set
getRiver
public java.lang.String getRiver()
- Returns:
- the river
appendRiver
public void appendRiver(java.lang.String river)
- Parameters:
river
- the river to set
getTurn
public java.lang.String getTurn()
- Returns:
- the turn
appendTurn
public void appendTurn(java.lang.String turn)
- Parameters:
turn
- the turn to set
getWinnings
public double getWinnings()
- Returns:
- the winnings
setWinnings
public void setWinnings(double winnings)
- Parameters:
winnings
- the winnings to set
storeToDb
public void storeToDb(java.sql.Connection dbConnection,
int handID)
throws java.sql.SQLException
- Store collected player data to database. Database table for
player is defined as following:
CREATE TABLE player (
hand_id integer NOT NULL,
account varchar(256) NOT NULL,
name varchar(256) NOT NULL,
position smallint NOT NULL,
flop varchar(256),
turn varchar(256),
river varchar(256),
money_in decimal,
winnings decimal,
card1 char(3),
card2 char(3),
PRIMARY KEY (hand_id, account, name)
);
- Parameters:
dbConnection
- handID
-
- Throws:
java.sql.SQLException