AssetsClient.Delete(WaitUntil, String, String, RequestContext) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Delete asset in a sentShare.
public virtual Azure.Operation Delete (Azure.WaitUntil waitUntil, string sentShareName, string assetName, Azure.RequestContext context = default);
abstract member Delete : Azure.WaitUntil * string * string * Azure.RequestContext -> Azure.Operation
override this.Delete : Azure.WaitUntil * string * string * Azure.RequestContext -> Azure.Operation
Public Overridable Function Delete (waitUntil As WaitUntil, sentShareName As String, assetName As String, Optional context As RequestContext = Nothing) As Operation
Parameters
- waitUntil
- WaitUntil
Completed if the method should wait to return until the long-running operation has completed on the service; Started if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples.
- sentShareName
- String
The name of the sent share.
- assetName
- String
The name of the asset.
- context
- RequestContext
The request context, which can override default behaviors of the client pipeline on a per-call basis.
Returns
The Operation representing an asynchronous operation on the service.
Exceptions
sentShareName
or assetName
is null.
sentShareName
or assetName
is an empty string, and was expected to be non-empty.
Service returned a non-success status code.
Examples
This sample shows how to call Delete with required parameters.
var credential = new DefaultAzureCredential();
var client = new AssetsClient("<https://my-service.azure.com>", credential);
var operation = client.Delete(WaitUntil.Completed, "<sentShareName>", "<assetName>");
var response = operation.WaitForCompletionResponse();
Console.WriteLine(response.Status)
Remarks
Delete an asset on a sent share.