public AutoScalingPolicy withRules(java.util.Collection<ScalingRule> rules) {
        setRules(rules);
        return this;
    }
<p>
The scale-in and scale-out rules that comprise the automatic scaling policy.
</p>

@param rules
       The scale-in and scale-out rules that comprise the automatic scaling policy.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-emr/src/main/java/com/amazonaws/services/elasticmapreduce/model/AutoScalingPolicy.java