public NetworkFirewallInvalidRouteConfigurationViolation withAffectedSubnets(String... affectedSubnets) {
        if (this.affectedSubnets == null) {
            setAffectedSubnets(new java.util.ArrayList<String>(affectedSubnets.length));
        }
        for (String ele : affectedSubnets) {
            this.affectedSubnets.add(ele);
        }
        return this;
    }
<p>
The subnets that are affected.
</p>
<p>
<b>NOTE:</b> This method appends the values to the existing list (if any). Use
{@link #setAffectedSubnets(java.util.Collection)} or {@link #withAffectedSubnets(java.util.Collection)} if you
want to override the existing values.
</p>

@param affectedSubnets
       The subnets that are affected.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-fms/src/main/java/com/amazonaws/services/fms/model/NetworkFirewallInvalidRouteConfigurationViolation.java