public void afterRuleAdded(RuleDescr rule) { for (final AttributeDescr at : attributes) { // check if rule overrides the attribute if (!rule.getAttributes().containsKey(at.getName())) { // if not, use default value rule.addAttribute(at); } } }
public AttributeDescr getAttribute(String name) { if (name != null) { for (AttributeDescr attr : this.attributes) { if (name.equals(attr.getName())) { return attr; } } } return null; }