Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## glassfrog.players
Class GUIPlayer

    java.lang.Object
      glassfrog.players.Player
          glassfrog.players.SocketPlayer
              glassfrog.players.GUIPlayer

All Implemented Interfaces:
  java.io.Serializable, java.lang.Comparable<Player>

    public class GUIPlayer

extends SocketPlayer

This class allows for the packaged Swordfish GUI to be connected as a Player. At this time, the GUI only allows for graphical representation of 2 Players, and thus should only be used for 2 Player games.

Author:
  jdavidso
See Also:
  Serialized Form

Field Summary

Fields inherited from class glassfrog.players.SocketPlayer
`br, pw, socket, ss`

Constructor Summary
`GUIPlayer(java.lang.String name, int buyIn, java.net.Socket socket)` Constructor for a GUI Player

Method Summary
`void` | `initTimeout(int timeout)` Used to set the player timeout to 60s per hand
`boolean` | `isGuiPlayer()` Overrides the @Player isGuiPlayer method and returns True
`java.lang.String` | `toString()` Returns GUI appended to the @Player representation of the object

Methods inherited from class glassfrog.players.SocketPlayer
`getAction, getPort, getSocket, initTimeout, isSocketPlayer, reconnect, shutdown, update`

Methods inherited from class glassfrog.players.Player
`addToScore, bet, call, compareTo, fold, getBuyIn, getCardString, getCurrentBet, getHandRank, getHandString, getName, getPosition, getScore, getSeat, getStack, getTotalCommitedToPot, isAAAIPlayer, isActed, isAllIn, isFolded, payout, postBlind, resetHand, resetPlayer, resetRound, resetStack, setBuyIn, setCardString, setHandRank, setHandString, setName, setPosition, setScore, setSeat, setStack, subtractTotalCommitedToPot, toShortString`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### GUIPlayer

    public GUIPlayer(java.lang.String name,
                     int buyIn,
                     java.net.Socket socket)
              throws java.io.IOException

  Constructor for a GUI Player

  Parameters:
    `name` - a @String representing the player's name
    `buyIn` - an int representing the requested buyIn amount
    `socket` - asocket for GUI to connect to
  Throws:
    `java.io.IOException`

Method Detail

### isGuiPlayer

    public boolean isGuiPlayer()

  Overrides the @Player isGuiPlayer method and returns True

  Overrides:
    `isGuiPlayer` in class `Player`
  Returns:
    True

### toString

    public java.lang.String toString()

  Returns GUI appended to the @Player representation of the object

  Overrides:
    `toString` in class `Player`
  Returns:
    GUI appended to the front of the @Player toString method

### initTimeout

    public void initTimeout(int timeout)

  Used to set the player timeout to 60s per hand

  Overrides:
    `initTimeout` in class `Player`
  Parameters:
    `timeout` - Timeout for the player's actions

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD