Package
Class
Tree
Deprecated
Index
Help
PREV NEXT
FRAMES
NO FRAMES
All Classes
B
C
D
F
G
H
I
M
R
S
T
B
BLACK
- Static variable in class
GameCard
Represents the suit color black (for clubs and spades).
Board
- Class in
<Unnamed>
Represents a 4 X 13 board of cards.
Board()
- Constructor for class
Board
Constructs a Board object.
C
Card
- Class in
<Unnamed>
Represents a playing card.
Card(int, int)
- Constructor for class
Card
Constructs a Card object with the given face value and suit value.
CLUBS
- Static variable in class
Card
Concentration
- Class in
<Unnamed>
This program plays a game of concentration (aka memory) for two players.
Concentration()
- Constructor for class
Concentration
D
deal()
- Method in class
Deck
Deals one card from the deck, decreasing the number of cards in the deck by one.
Deck
- Class in
<Unnamed>
Represents a deck of cards.
Deck()
- Constructor for class
Deck
Constructs a new Deck object containing 52 cards.
DECK_SIZE
- Static variable in class
Deck
DIAMONDS
- Static variable in class
Card
F
flip()
- Method in class
GameCard
Flips the card, either from face up to face down or vice versa.
G
GameCard
- Class in
<Unnamed>
Represents a playing card that can be either face up or face down.
GameCard(int, int, boolean)
- Constructor for class
GameCard
Constructs a GameCard object with the given face value and suit value.
GameCard(Card, boolean)
- Constructor for class
GameCard
Constructs a GameCard object with the same face value and suit value as the Card object given.
getCard(int, int)
- Method in class
Board
Returns the card at the given row and column.
getFace()
- Method in class
Card
Returns the face value of the card.
getSuit()
- Method in class
Card
Returns the suit of the card.
getSuitColor()
- Method in class
GameCard
Returns the suit color of the card.
H
HEARTS
- Static variable in class
Card
I
invalidBoardPosition(int, int)
- Method in class
Board
Returns true if and only if (row, col) is not a valid position on the board.
isEmpty()
- Method in class
Board
Returns true if there are no more cards on the board.
isFaceUp()
- Method in class
GameCard
Returns true if the card is face up and false otherwise.
M
main(String[])
- Static method in class
Concentration
match(GameCard)
- Method in class
GameCard
Returns true if this card matches the given card and false otherwise.
R
RED
- Static variable in class
GameCard
Represents the suit color red (for diamonds and hearts).
removeCard(int, int)
- Method in class
Board
Removes the card at the given row and column.
removeCard(GameCard)
- Method in class
Board
Removes the given card from the board.
reset()
- Method in class
Deck
Resets the deck so that it has all its cards.
S
shuffle()
- Method in class
Deck
Shuffles the deck (i.e.
SPADES
- Static variable in class
Card
T
toString()
- Method in class
Board
Returns a string representation of the board suitable for printing with System.out.
toString()
- Method in class
Card
Returns a String representation of a Card object.
toString()
- Method in class
Deck
Returns a String representation of the Deck object.
toString()
- Method in class
GameCard
Returns a String representing the game card.
B
C
D
F
G
H
I
M
R
S
T
Package
Class
Tree
Deprecated
Index
Help
PREV NEXT
FRAMES
NO FRAMES
All Classes