public UpdateEndpointWeightsAndCapacitiesRequest withDesiredWeightsAndCapacities(java.util.Collection<DesiredWeightAndCapacity> desiredWeightsAndCapacities) {
        setDesiredWeightsAndCapacities(desiredWeightsAndCapacities);
        return this;
    }
<p>
An object that provides new capacity and weight values for a variant.
</p>

@param desiredWeightsAndCapacities
       An object that provides new capacity and weight values for a variant.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-sagemaker/src/main/java/com/amazonaws/services/sagemaker/model/UpdateEndpointWeightsAndCapacitiesRequest.java