public DeploymentTargets withAccounts(String... accounts) {
        if (this.accounts == null) {
            setAccounts(new com.amazonaws.internal.SdkInternalList<String>(accounts.length));
        }
        for (String ele : accounts) {
            this.accounts.add(ele);
        }
        return this;
    }
<p>
The names of one or more Amazon Web Services accounts for which you want to deploy stack set updates.
</p>
<p>
<b>NOTE:</b> This method appends the values to the existing list (if any). Use
{@link #setAccounts(java.util.Collection)} or {@link #withAccounts(java.util.Collection)} if you want to override
the existing values.
</p>

@param accounts
       The names of one or more Amazon Web Services accounts for which you want to deploy stack set updates.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-cloudformation/src/main/java/com/amazonaws/services/cloudformation/model/DeploymentTargets.java