IndividualEnrollmentsClient.RunBulkOperationAsync 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.
Create, update or delete a set of individual enrollment groups.
public System.Threading.Tasks.Task<Microsoft.Azure.Devices.Provisioning.Service.BulkEnrollmentOperationResult> RunBulkOperationAsync (Microsoft.Azure.Devices.Provisioning.Service.BulkOperationMode bulkOperationMode, System.Collections.Generic.IEnumerable<Microsoft.Azure.Devices.Provisioning.Service.IndividualEnrollment> individualEnrollments, System.Threading.CancellationToken cancellationToken = default);
member this.RunBulkOperationAsync : Microsoft.Azure.Devices.Provisioning.Service.BulkOperationMode * seq<Microsoft.Azure.Devices.Provisioning.Service.IndividualEnrollment> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Devices.Provisioning.Service.BulkEnrollmentOperationResult>
Public Function RunBulkOperationAsync (bulkOperationMode As BulkOperationMode, individualEnrollments As IEnumerable(Of IndividualEnrollment), Optional cancellationToken As CancellationToken = Nothing) As Task(Of BulkEnrollmentOperationResult)
Parameters
- bulkOperationMode
- BulkOperationMode
The BulkOperationMode that defines the single operation to do over the individualEnrollments. It cannot be null.
- individualEnrollments
- IEnumerable<IndividualEnrollment>
The collection of IndividualEnrollment that contains the description of each individualEnrollment. It cannot be null or empty.
- cancellationToken
- CancellationToken
The cancellation token.
Returns
An object with the result of each operation.
Exceptions
If the client failed to send the request or service was not able to execute the bulk operation.
If the provided individualEnrollments
is null.
If the provided individualEnrollments
is an empty collection.
If the client failed to send the request or service was not able to execute the bulk operation.
If the provided cancellationToken
has requested cancellation.
Remarks
This API provide the means to do a single operation over multiple individualEnrollments. A valid operation is determined by BulkOperationMode, and can be 'create', 'update', 'updateIfMatchETag', or 'delete'.
Applies to
Azure SDK for .NET