com.asdf.plugins.pokergames
Interface PlayerInfo

All Known Implementing Classes:
OurPlayerInfo

public interface PlayerInfo

interface for getting all the public information concerning one player

Author:
rimpila

Method Summary
 java.lang.String getAccountName()
          Returns the account name of this player.
 double getAmountCallable()
          Get the amount of the current bet that the player can call
 double getAmountInPot()
          Obtain the amount the player has invested in the pot.
 double getAmountInPotThisRound()
          Obtain the amount the player has invested in the pot this round
 double getAmountRaiseable()
          Get the maximum amount the player can raise.
 double getAmountToCall()
          Determine the amount a player must pay to stay in the game
 double getBankRoll()
          Get the current bankroll
 double getBankRollAtStartOfHand()
          Get the player's bankroll at the start of the hand (i.e., before any actions including antes and blinds).
 double getBankRollInSmallBets()
          Get the current bankroll as a multiple of the big blind
 GameInfo getGameInfo()
          Get the context of the last action made by this player.
 int getLastAction()
          A single integer code for the last action made
 java.lang.String getName()
          Obtain the player's name
 double getNetGain()
          Get the net amount won or lost since the start of the current hand
 double getRaiseAmount(double arg0)
          Return the amount the player can raise, given the desired amount to raise.
 Hand getRevealedHand()
          Obtain the hand revealed by this player
 int getSeat()
          Get the player's seat number in the GameInfo
 boolean hasActedThisRound()
          Check if a player has made at least one action this round
 boolean hasEnoughToRaise()
          Check if the player has enough chips to complete a raise
 PokerGame.Blind hasToPostBlind()
          Get whether the player has sat out some blinds, and has to pay any as a penalty for entering the game
 boolean inGame()
          See if the player is dealt into the current game
 boolean isActive()
          Check if the player is still active in the hand
 boolean isAllIn()
          Check if the player is all-in
 boolean isButton()
          Check if the player is all-in
 boolean isCommitted()
          Check if the player has voluntarily committed this round
 boolean isFolded()
          Check if the player has folded
 boolean isSittingOut()
          Check if the player is sitting out
 

Method Detail

hasToPostBlind

PokerGame.Blind hasToPostBlind()
Get whether the player has sat out some blinds, and has to pay any as a penalty for entering the game

Returns:
missed blinds

getAmountCallable

double getAmountCallable()
Get the amount of the current bet that the player can call

Returns:
how much the player can pay of the amount he should call

getAmountInPot

double getAmountInPot()
Obtain the amount the player has invested in the pot.

Returns:
the amount the player has in the pot of the current hand

getAmountInPotThisRound

double getAmountInPotThisRound()
Obtain the amount the player has invested in the pot this round

Returns:
the amount the player has invested in the pot this round

getAmountRaiseable

double getAmountRaiseable()
Get the maximum amount the player can raise.

Returns:
the amount the player will be able to raise, thus, either the upper limit for raises, or the total bankroll

getAmountToCall

double getAmountToCall()
Determine the amount a player must pay to stay in the game

Returns:
the difference between the player who has bet most in the pot, and this players amount in the pot

getBankRoll

double getBankRoll()
Get the current bankroll

Returns:
the amount of money the player has in his disposal in the table

getBankRollAtStartOfHand

double getBankRollAtStartOfHand()
Get the player's bankroll at the start of the hand (i.e., before any actions including antes and blinds).

Returns:
the amount the player had in his bankroll before any antes, blinds or bets

getBankRollInSmallBets

double getBankRollInSmallBets()
Get the current bankroll as a multiple of the big blind

Returns:
the players bankroll divided by the size of the big blind

getGameInfo

GameInfo getGameInfo()
Get the context of the last action made by this player.

Returns:
the GameInfo saved when doing latest action

getLastAction

int getLastAction()
A single integer code for the last action made

Returns:
one of [Holdem.FOLD, Holdem.CALL, Holdem.RAISE]

getName

java.lang.String getName()
Obtain the player's name

Returns:
the name of the player

getNetGain

double getNetGain()
Get the net amount won or lost since the start of the current hand

Returns:
the difference between current bankroll and the bankroll at the start of hand

getRaiseAmount

double getRaiseAmount(double arg0)
Return the amount the player can raise, given the desired amount to raise.

Parameters:
arg0 - the amount desired to raise
Returns:
the amount player is able to raise given the desired

getRevealedHand

Hand getRevealedHand()
Obtain the hand revealed by this player

Returns:
the players hole cards, if he has revealed them, otherwise 2 invalid cards, if he has two, otherwise empty hand

getSeat

int getSeat()
Get the player's seat number in the GameInfo

Returns:
the players seat number

hasActedThisRound

boolean hasActedThisRound()
Check if a player has made at least one action this round

Returns:
true if the player has acted this round

hasEnoughToRaise

boolean hasEnoughToRaise()
Check if the player has enough chips to complete a raise

Returns:
true if the player has enough for minimum raise after paying what he has to call

inGame

boolean inGame()
See if the player is dealt into the current game

Returns:
true if the player is dealt in

isActive

boolean isActive()
Check if the player is still active in the hand

Returns:
true if the player is active in current hand

isAllIn

boolean isAllIn()
Check if the player is all-in

Returns:
true if the player is all-in

isButton

boolean isButton()
Check if the player is all-in

Returns:
true if the player is all-in

isCommitted

boolean isCommitted()
Check if the player has voluntarily committed this round

Returns:
true if the player has committed

isFolded

boolean isFolded()
Check if the player has folded

Returns:
true if the player has folded

isSittingOut

boolean isSittingOut()
Check if the player is sitting out

Returns:
true if the player is sitting out

getAccountName

java.lang.String getAccountName()
Returns the account name of this player.

Returns:
Account name.