package card; public class Card { private int value; private Suit suit; public Card(int value, Suit suit) { this.value = value; this.suit = suit; } public int getValue() { return this.value; } public Suit getSuit() { return this.suit; } public String displayCard() { String name = ""; if (this.value < 1 || this.value > 13) { name += "UNKNOWN"; } else if (this.value > 1 && this.value < 11) { name += this.value; } else { switch (this.value) { case 1: name += "ace"; break; case 11: name += "jack"; break; case 12: name += "queen"; break; case 13: name += "king"; break; default: name += "UNKNOWN"; } } switch (this.suit) { case CLUBS: name += " of clubs"; break; case DIAMONDS: name += " of diamonds"; break; case HEARTS: name += " of hearts"; break; case SPADES: name += " of spades"; break; } return name; } }