public CreateFleetRequest withMetricGroups(String... metricGroups) {
        if (this.metricGroups == null) {
            setMetricGroups(new java.util.ArrayList<String>(metricGroups.length));
        }
        for (String ele : metricGroups) {
            this.metricGroups.add(ele);
        }
        return this;
    }
<p>
The name of an Amazon Web Services CloudWatch metric group to add this fleet to. A metric group is used to
aggregate the metrics for multiple fleets. You can specify an existing metric group name or set a new name to
create a new metric group. A fleet can be included in only one metric group at a time.
</p>
<p>
<b>NOTE:</b> This method appends the values to the existing list (if any). Use
{@link #setMetricGroups(java.util.Collection)} or {@link #withMetricGroups(java.util.Collection)} if you want to
override the existing values.
</p>

@param metricGroups
       The name of an Amazon Web Services CloudWatch metric group to add this fleet to. A metric group is used to
       aggregate the metrics for multiple fleets. You can specify an existing metric group name or set a new name
       to create a new metric group. A fleet can be included in only one metric group at a time.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-gamelift/src/main/java/com/amazonaws/services/gamelift/model/CreateFleetRequest.java