class Category {

	public boolean matches(Transaction transaction) {
		checkNotNull(transaction);
		if (!Strings.isNullOrEmpty(transaction.getCategoryName())) {
			return getName().equals(transaction.getCategoryName());
		}
		for (MatchRule matchRule : getMatchRules()) {
			if (matchRule.matches(transaction)) {
				return true;
			}
		}
		return false;
	}

	public  Category(String name);
	public  Category(String name, List<MatchRule> matchRules);

}