|
|||||||||
PREV NEXT | FRAMES NO FRAMES |
Uses of Card in program4 |
---|
Subclasses of Card in program4 | |
---|---|
class |
GoFishCard
Title: The GoFishCard Class |
Fields in program4 with type parameters of type Card | |
---|---|
private java.util.ArrayList<Card> |
Deck.cards
ArrayList of Cards |
Methods in program4 that return Card | |
---|---|
Card |
Deck.deal()
Returns a card from the Deck |
Methods in program4 with parameters of type Card | |
---|---|
int |
Card.compareByRank(Card otherCard)
compareByRank -- this method compares 2 Card objects by rank and returns a negative integer, zero, or a positive integer as this Card is less than, equal to, or greater than the other Card. For example the following call: card1.compareByRank(card2); compares if the rank of card1 is greater than card2, is equal to card2, or is less than card2 and returns the appropriate value |
int |
Card.compareBySuit(Card otherCard)
compareBySuit -- this method compares 2 Card objects by suit and returns a negative integer, zero, or a positive integer as this Card is less than, equal to, or greater than the other Card. For example the following call: card1.compareBySuit(card2); compares if the suit of card1 is greater than card2, is equal to card2, or is less than card2 and returns the appropriate value |
boolean |
Card.equals(Card otherCard)
equals -- this method indicates whether some other Card is "equal to" this one. |
|
|||||||||
PREV NEXT | FRAMES NO FRAMES |