All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.lotspiech.poker.HandWithDiscard

java.lang.Object
   |
   +----com.lotspiech.poker.BunchOfCards
           |
           +----com.lotspiech.poker.Hand
                   |
                   +----com.lotspiech.poker.HandWithDiscard

public class HandWithDiscard
extends Hand
implements Cloneable
This type of Hand has an ordered list of cards, of which some may be discarded.

Copyright 2001, 2002 by Jeffrey B. Lotspiech. This program is open source; it is licensed under the Common Public License Version 0.5.

Author:
Jeffrey B. Lotspiech

Variable Index

 o cards
 o COPYRIGHT

Constructor Index

 o HandWithDiscard(Card[])
Discard constructor comment.
 o HandWithDiscard(String)
Discard constructor comment.

Method Index

 o cardIsDiscarded(int)
This method was created in VisualAge.
 o clone()
This method was created in VisualAge.
 o discardCard(int)
This method was created in VisualAge.
 o equals(HandWithDiscard)
This method was created in VisualAge.
 o getCards()
This method was created in VisualAge.
 o toString()
This method was created in VisualAge.

Variables

 o COPYRIGHT
 private static final String COPYRIGHT
 o cards
 private Card cards[]

Constructors

 o HandWithDiscard
 public HandWithDiscard(Card cards[])
Discard constructor comment.

Parameters:
machine - com.lotspiech.poker.Machine
cardNames - java.lang.String
Throws: Exception
The exception description.
 o HandWithDiscard
 public HandWithDiscard(String cardNames) throws Exception
Discard constructor comment.

Parameters:
machine - com.lotspiech.poker.Machine
cardNames - java.lang.String
Throws: Exception
The exception description.

Methods

 o cardIsDiscarded
 public boolean cardIsDiscarded(int index)
This method was created in VisualAge.

Parameters:
index - int
Returns:
boolean
 o clone
 public Object clone()
This method was created in VisualAge.

Overrides:
clone in class Object
 o discardCard
 public void discardCard(int index) throws Exception
This method was created in VisualAge.

Parameters:
index - int
 o equals
 public boolean equals(HandWithDiscard hand)
This method was created in VisualAge.

Parameters:
hand - com.lotspiech.poker.HandWithDiscard
Returns:
boolean
 o getCards
 public Card[] getCards()
This method was created in VisualAge.

Returns:
com.lotspiech.poker.Card[]
 o toString
 public String toString()
This method was created in VisualAge.

Returns:
java.lang.String
Overrides:
toString in class BunchOfCards

All Packages  Class Hierarchy  This Package  Previous  Next  Index