/** * Set the access control list (ACL) permissions for an object that already exists in a bucket * * @param string $bucket * @param string $key * @param string $acl private | public-read | public-read-write | authenticated-read | bucket-owner-read | bucket-owner-full-control * * @return mixed */ public function putObjectAcl($bucket, $key, $acl) { $params = ['Bucket' => $bucket, 'Key' => $key, 'Acl' => $acl]; return $this->instance->putObjectAcl($params); }
/** * Get mimetype of a file * * @param string $path * @param string $visibility * @return array file metadata */ public function setVisibility($path, $visibility) { $options = $this->getOptions($path, array('ACL' => $visibility === AdapterInterface::VISIBILITY_PUBLIC ? 'public-read' : 'private')); $this->client->putObjectAcl($options); return compact('visibility'); }
/** * putObjectAcl * * @param array $params * * @return \Guzzle\Service\Resource\Model */ public function putObjectAcl(array $params = array()) { $params['Bucket'] = $this->name; return $this->client->putObjectAcl($params); }