CloudBlob.delete Method

Definition

Overloads

delete()

Deletes the blob.

If a delete retention policy is enabled on the service, the blob will be retained for a specified period of time, before being removed permanently by garbage collection.

delete(final DeleteSnapshotsOption deleteSnapshotsOption, final AccessCondition accessCondition, BlobRequestOptions options, OperationContext opContext)

Deletes the blob using the specified snapshot and request options, and operation context.

If a delete retention policy is enabled on the service, the blob will be retained for a specified period of time, before being removed permanently by garbage collection.

A blob that has snapshots cannot be deleted unless the snapshots are also deleted. If a blob has snapshots, use the DeleteSnapshotsOption#DELETE_SNAPSHOTS_ONLY or DeleteSnapshotsOption#INCLUDE_SNAPSHOTS value in the parameter to specify how the snapshots should be handled when the blob is deleted.

delete()

Deletes the blob.

If a delete retention policy is enabled on the service, the blob will be retained for a specified period of time, before being removed permanently by garbage collection.

public final void delete()
Returns
final void
Exceptions

If a storage service error occurred.

delete(final DeleteSnapshotsOption deleteSnapshotsOption, final AccessCondition accessCondition, BlobRequestOptions options, OperationContext opContext)

Deletes the blob using the specified snapshot and request options, and operation context.

If a delete retention policy is enabled on the service, the blob will be retained for a specified period of time, before being removed permanently by garbage collection.

A blob that has snapshots cannot be deleted unless the snapshots are also deleted. If a blob has snapshots, use the DeleteSnapshotsOption#DELETE_SNAPSHOTS_ONLY or DeleteSnapshotsOption#INCLUDE_SNAPSHOTS value in the parameter to specify how the snapshots should be handled when the blob is deleted.

public final void delete(final DeleteSnapshotsOption deleteSnapshotsOption, final AccessCondition accessCondition, BlobRequestOptions options, OperationContext opContext)
Parameters
deleteSnapshotsOption
final DeleteSnapshotsOption

A DeleteSnapshotsOption object that indicates whether to delete only snapshots, or the blob and its snapshots.

accessCondition
final AccessCondition

An AccessCondition object that represents the access conditions for the blob.

options
BlobRequestOptions

A BlobRequestOptions object that specifies any additional options for the request. Specifying null will use the default request options from the associated service client ( CloudBlobClient).

opContext
OperationContext

An OperationContext object that represents the context for the current operation. This object is used to track requests to the storage service, and to provide additional runtime information about the operation.

Returns
final void
Exceptions

If a storage service error occurred.