* The canned ACL to apply to the resource.
* @param originalRequest
* The original, user facing request object.
*/
private void setAcl(String bucketName, String key, String versionId, CannedAccessControlList cannedAcl, AmazonWebServiceRequest originalRequest) {
if (originalRequest == null) originalRequest = new GenericBucketRequest(bucketName);
Request<AmazonWebServiceRequest> request = createRequest(bucketName, key, originalRequest, HttpMethodName.PUT);
request.addParameter("acl", null);
request.addHeader(Headers.S3_CANNED_ACL, cannedAcl.toString());
if (versionId != null) request.addParameter("versionId", versionId);