public S3CopyObjectOperation withAccessControlGrants(S3Grant... accessControlGrants) {
        if (this.accessControlGrants == null) {
            setAccessControlGrants(new java.util.ArrayList<S3Grant>(accessControlGrants.length));
        }
        for (S3Grant ele : accessControlGrants) {
            this.accessControlGrants.add(ele);
        }
        return this;
    }
<p/>
<note>
<p>
This functionality is not supported by directory buckets.
</p>
</note>
<p>
<b>NOTE:</b> This method appends the values to the existing list (if any). Use
{@link #setAccessControlGrants(java.util.Collection)} or {@link #withAccessControlGrants(java.util.Collection)}
if you want to override the existing values.
</p>

@param accessControlGrants
       <note>
       <p>
       This functionality is not supported by directory buckets.
       </p>
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-s3control/src/main/java/com/amazonaws/services/s3control/model/S3CopyObjectOperation.java