poker
Class Pot
java.lang.Object
poker.Pot
- All Implemented Interfaces:
- java.io.Serializable
public class Pot
- extends java.lang.Object
- implements java.io.Serializable
Handles a Pot data structure, which accumulates money from
players, and can break into multiple side pots.
- Author:
- adavidson
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Pot
public Pot(GameInfo gi)
payPot
public void payPot(int amount,
PlayerInfo pi)
getSidePot
public Pot getSidePot()
setThreshold
public void setThreshold(int t)
getThreshold
public int getThreshold()
getSize
public int getSize()
getPots
public Pot[] getPots()
getNumPots
public int getNumPots()
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object
hasSidePot
public boolean hasSidePot()
- Returns:
- true if there is a side pot
removeUncalledChips
public int removeUncalledChips()
- Remove all uncalled chips from the pot
- Returns:
- the amount removed from the pot.
removeUncalledChips
public int removeUncalledChips(Pot p)
- Remove all uncalled chips from the pot
- Returns:
- the amount removed from the pot.