Webiny\Component\Amazon\Bridge\S3\S3::deleteObject PHP Method

deleteObject() public method

If there isn't a null version, Amazon S3 does not remove any objects.
public deleteObject ( string $bucket, string $key, array $params = [] ) : mixed
$bucket string
$key string
$params array
return mixed
    public function deleteObject($bucket, $key, array $params = [])
    {
        $params['Bucket'] = $bucket;
        $params['Key'] = $key;
        return $this->instance->deleteObject($params);
    }

Usage Example

コード例 #1
0
ファイル: S3.php プロジェクト: Webiny/Framework
 /**
  * Removes the null version (if there is one) of an object and inserts a delete marker, which becomes the latest version of the object.
  * If there isn't a null version, Amazon S3 does not remove any objects.
  *
  * @param string $bucket
  * @param string $key
  * @param array  $params
  *
  * @return mixed
  */
 public function deleteObject($bucket, $key, array $params = [])
 {
     return $this->instance->deleteObject($bucket, $key, $params);
 }