public class Deck
extends java.lang.Object
| Constructor and Description |
|---|
Deck()
Constructor for Deck.
|
Deck(java.util.ArrayList<Card> cards)
Constructor for Deck.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addCard(Card card)
Adds a card to the end of the deck
|
Card |
removeCard()
Removes a card from the beginning of the deck
|
void |
shuffle()
Shuffles the deck.
|
private java.util.ArrayList<Card> deck
public Deck()
public Deck(java.util.ArrayList<Card> cards)
cards - List of cards to fill the deckpublic void addCard(Card card)
card - Card that will be added to the deckpublic Card removeCard()
public void shuffle()