com.asdf.plugins.pokergames
Class PlayerPosition

java.lang.Object
  extended by com.asdf.plugins.pokergames.PlayerPosition
All Implemented Interfaces:
java.lang.Comparable<PlayerPosition>

public class PlayerPosition
extends java.lang.Object
implements java.lang.Comparable<PlayerPosition>

Note: this class has a natural ordering that is inconsistent with equals. Class for collecting information of the winnings for each player


Constructor Summary
PlayerPosition(int seat, double amountInPot, BestHand handValue)
          Constructor
 
Method Summary
 void addWinnings(double amount)
          adds given amount to the player's winnings
 int compareTo(PlayerPosition o)
           
 double getAmountInPot()
           
 int getHandValue()
           
 int getSeat()
           
 int[] getWinningCardsPositions()
           
 double getWinnings()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PlayerPosition

public PlayerPosition(int seat,
                      double amountInPot,
                      BestHand handValue)
Constructor

Parameters:
seat - seat of the player
amountInPot - amount the player had in the pot
handValue - hand value as calculated by handEval
Method Detail

compareTo

public int compareTo(PlayerPosition o)
Specified by:
compareTo in interface java.lang.Comparable<PlayerPosition>

getSeat

public int getSeat()
Returns:
the seat

getAmountInPot

public double getAmountInPot()
Returns:
the amountInPot

getHandValue

public int getHandValue()
Returns:
the handValue

getWinningCardsPositions

public int[] getWinningCardsPositions()
Returns:
integer table of five cards, out of seven, the positions of the cards that make the best possible hand

addWinnings

public void addWinnings(double amount)
adds given amount to the player's winnings

Parameters:
amount -

getWinnings

public double getWinnings()
Returns:
the winnings