public boolean matches(Card card) {
		if (card == null) {
			return false;
		}
		switch (type) {
		case ANY_SUIT:
			return card.getValue() == value;
		case ANY_VALUE:
			return card.getSuit() == suit;
		case RANDOM:
			return true;
		case CONTAINED_BY_SET:
			for (CardPattern pattern : cardPatterns) {
				if (pattern.matches(card)) {
					return true;
				}
			}
			return false;
		case EXACT:
			return card.getValue() == value && card.getSuit() == suit;
		}
		return false;
	}