public Deployment withCapacityProviderStrategy(CapacityProviderStrategyItem... capacityProviderStrategy) {
        if (this.capacityProviderStrategy == null) {
            setCapacityProviderStrategy(new com.amazonaws.internal.SdkInternalList<CapacityProviderStrategyItem>(capacityProviderStrategy.length));
        }
        for (CapacityProviderStrategyItem ele : capacityProviderStrategy) {
            this.capacityProviderStrategy.add(ele);
        }
        return this;
    }
<p>
The capacity provider strategy that the deployment is using.
</p>
<p>
<b>NOTE:</b> This method appends the values to the existing list (if any). Use
{@link #setCapacityProviderStrategy(java.util.Collection)} or
{@link #withCapacityProviderStrategy(java.util.Collection)} if you want to override the existing values.
</p>

@param capacityProviderStrategy
       The capacity provider strategy that the deployment is using.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-ecs/src/main/java/com/amazonaws/services/ecs/model/Deployment.java