public ReplicationConfiguration withRules(java.util.Collection<ReplicationRule> rules) {
        setRules(rules);
        return this;
    }
<p>
An array of objects representing the replication destinations and repository filters for a replication
configuration.
</p>

@param rules
       An array of objects representing the replication destinations and repository filters for a replication
       configuration.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-ecr/src/main/java/com/amazonaws/services/ecr/model/ReplicationConfiguration.java