public Ec2InstanceAttributes withRequestedEc2SubnetIds(String... requestedEc2SubnetIds) {
        if (this.requestedEc2SubnetIds == null) {
            setRequestedEc2SubnetIds(new com.amazonaws.internal.SdkInternalList<String>(requestedEc2SubnetIds.length));
        }
        for (String ele : requestedEc2SubnetIds) {
            this.requestedEc2SubnetIds.add(ele);
        }
        return this;
    }
public Ec2InstanceAttributes withRequestedEc2SubnetIds ( String ... requestedEc2SubnetIds ) { if ( this . requestedEc2SubnetIds == null ) { setRequestedEc2SubnetIds ( new com . amazonaws . internal . SdkInternalList < String > ( requestedEc2SubnetIds . length ) ) ; } for ( String ele : requestedEc2SubnetIds ) { this . requestedEc2SubnetIds . add ( ele ) ; } return this ; }
<p>
Applies to clusters configured with the instance fleets option. Specifies the unique identifier of one or more
Amazon EC2 subnets in which to launch EC2 cluster instances. Subnets must exist within the same VPC. Amazon EMR
chooses the EC2 subnet with the best fit from among the list of <code>RequestedEc2SubnetIds</code>, and then
launches all cluster instances within that Subnet. If this value is not specified, and the account and region
support EC2-Classic networks, the cluster launches instances in the EC2-Classic network and uses
<code>RequestedEc2AvailabilityZones</code> instead of this setting. If EC2-Classic is not supported, and no
Subnet is specified, Amazon EMR chooses the subnet for you. <code>RequestedEc2SubnetIDs</code> and
<code>RequestedEc2AvailabilityZones</code> cannot be specified together.
</p>
<p>
<b>NOTE:</b> This method appends the values to the existing list (if any). Use
{@link #setRequestedEc2SubnetIds(java.util.Collection)} or
{@link #withRequestedEc2SubnetIds(java.util.Collection)} if you want to override the existing values.
</p>

@param requestedEc2SubnetIds
Applies to clusters configured with the instance fleets option. Specifies the unique identifier of one or
more Amazon EC2 subnets in which to launch EC2 cluster instances. Subnets must exist within the same VPC.
Amazon EMR chooses the EC2 subnet with the best fit from among the list of
<code>RequestedEc2SubnetIds</code>, and then launches all cluster instances within that Subnet. If this
value is not specified, and the account and region support EC2-Classic networks, the cluster launches
instances in the EC2-Classic network and uses <code>RequestedEc2AvailabilityZones</code> instead of this
setting. If EC2-Classic is not supported, and no Subnet is specified, Amazon EMR chooses the subnet for
you. <code>RequestedEc2SubnetIDs</code> and <code>RequestedEc2AvailabilityZones</code> cannot be specified
together.
@return Returns a reference to this object so that method calls can be chained together.