Share via


Entity.BatchDeleteAsync Method

Definition

Overloads

Name Description
BatchDeleteAsync(IEnumerable<String>, RequestContext)

[Protocol Method] Delete a list of entities in bulk identified by their GUIDs or unique attributes.

BatchDeleteAsync(IEnumerable<String>, CancellationToken)

Delete a list of entities in bulk identified by their GUIDs or unique attributes.

BatchDeleteAsync(IEnumerable<String>, RequestContext)

Source:
Entity.cs

[Protocol Method] Delete a list of entities in bulk identified by their GUIDs or unique attributes.

public virtual System.Threading.Tasks.Task<Azure.Response> BatchDeleteAsync(System.Collections.Generic.IEnumerable<string> guid, Azure.RequestContext context);
abstract member BatchDeleteAsync : seq<string> * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
override this.BatchDeleteAsync : seq<string> * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
Public Overridable Function BatchDeleteAsync (guid As IEnumerable(Of String), context As RequestContext) As Task(Of Response)

Parameters

guid
IEnumerable<String>

An array of GUIDs of entities to delete.

context
RequestContext

The request context, which can override default behaviors of the client pipeline on a per-call basis.

Returns

The response returned from the service.

Exceptions

guid is null.

Service returned a non-success status code.

Examples

This sample shows how to call BatchDeleteAsync and parse the result.

Uri endpoint = new Uri("<endpoint>");
TokenCredential credential = new DefaultAzureCredential();
Entity client = new DataMapClient(endpoint, credential).GetEntityClient();

Response response = await client.BatchDeleteAsync(new string[] { "18e06957-e265-967a-07f1-e14e2ab8940f", "cc0730ba-9b30-41f0-6953-559d17626d2b" }, null);

JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement;
Console.WriteLine(result.ToString());

Applies to

BatchDeleteAsync(IEnumerable<String>, CancellationToken)

Source:
Entity.cs

Delete a list of entities in bulk identified by their GUIDs or unique attributes.

public virtual System.Threading.Tasks.Task<Azure.Response<Azure.Analytics.Purview.DataMap.EntityMutationResult>> BatchDeleteAsync(System.Collections.Generic.IEnumerable<string> guid, System.Threading.CancellationToken cancellationToken = default);
abstract member BatchDeleteAsync : seq<string> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.Analytics.Purview.DataMap.EntityMutationResult>>
override this.BatchDeleteAsync : seq<string> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.Analytics.Purview.DataMap.EntityMutationResult>>
Public Overridable Function BatchDeleteAsync (guid As IEnumerable(Of String), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of EntityMutationResult))

Parameters

guid
IEnumerable<String>

An array of GUIDs of entities to delete.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

guid is null.

Examples

This sample shows how to call BatchDeleteAsync.

Uri endpoint = new Uri("<endpoint>");
TokenCredential credential = new DefaultAzureCredential();
Entity client = new DataMapClient(endpoint, credential).GetEntityClient();

Response<EntityMutationResult> response = await client.BatchDeleteAsync(new string[] { "18e06957-e265-967a-07f1-e14e2ab8940f", "cc0730ba-9b30-41f0-6953-559d17626d2b" });

Applies to