public CheckCapacityRequest withRules(java.util.Collection<Rule> rules) {
        setRules(rules);
        return this;
    }
<p>
An array of <a>Rule</a> that you're configuring to use in a rule group or web ACL.
</p>

@param rules
       An array of <a>Rule</a> that you're configuring to use in a rule group or web ACL.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-wafv2/src/main/java/com/amazonaws/services/wafv2/model/CheckCapacityRequest.java