Amazon.S3.Util.AmazonS3Util.DeleteS3BucketWithObjectsAsync C# (CSharp) Method

DeleteS3BucketWithObjectsAsync() public static method

Deletes an S3 bucket which contains objects. An S3 bucket which contains objects cannot be deleted until all the objects in it are deleted. This method deletes all the objects in the specified bucket and then deletes the bucket itself.
public static DeleteS3BucketWithObjectsAsync ( IAmazonS3 s3Client, string bucketName ) : Task
s3Client IAmazonS3 The Amazon S3 Client to use for S3 specific operations.
bucketName string The bucket to be deleted.
return Task
        public static Task DeleteS3BucketWithObjectsAsync(IAmazonS3 s3Client, string bucketName)
        {
            var cancelSource = new CancellationTokenSource();
            return DeleteS3BucketWithObjectsAsync(s3Client, bucketName, cancelSource.Token);
        }

Same methods

AmazonS3Util::DeleteS3BucketWithObjectsAsync ( IAmazonS3 s3Client, string bucketName, CancellationToken token ) : Task
AmazonS3Util::DeleteS3BucketWithObjectsAsync ( IAmazonS3 s3Client, string bucketName, Amazon.S3.Util.S3DeleteBucketWithObjectsOptions deleteOptions ) : Task
AmazonS3Util::DeleteS3BucketWithObjectsAsync ( IAmazonS3 s3Client, string bucketName, Amazon.S3.Util.S3DeleteBucketWithObjectsOptions deleteOptions, Action updateCallback, CancellationToken token ) : Task
AmazonS3Util::DeleteS3BucketWithObjectsAsync ( IAmazonS3 s3Client, string bucketName, Amazon.S3.Util.S3DeleteBucketWithObjectsOptions deleteOptions, CancellationToken token ) : Task