public void setRules(final List<AttributeRule> rules) {
        Validate.notEmpty(rules, "Argument 'rules' cannot be null or empty.");

        this.rules = Collections.unmodifiableList(new ArrayList<>(rules));
    }
public void setRules ( final List < AttributeRule > rules ) { Validate . notEmpty ( rules , "Argument 'rules' cannot be null or empty." ) ; this . rules = Collections . unmodifiableList ( new ArrayList < > ( rules ) ) ; }
@param rules the rules to set