Table of Contents

Method TryDeleteInBatches

Namespace
Skyline.DataMiner.Utils.DOM.Extensions
Assembly
Skyline.DataMiner.Utils.DOM.dll

TryDeleteInBatches<T, K>(IBulkCrudTryHelperComponent<T, K>, IEnumerable<T>, out BulkDeleteResult<K>)

Deletes a collection of instances in batches.

public static bool TryDeleteInBatches<T, K>(this IBulkCrudTryHelperComponent<T, K> helper, IEnumerable<T> instances, out BulkDeleteResult<K> result) where T : IManagerIdentifiableObject<K>, DataType where K : IEquatable<K>

Parameters

helper IBulkCrudTryHelperComponent<T, K>

The bulk CRUD helper component used to perform delete operations.

instances IEnumerable<T>

The instances to delete.

result BulkDeleteResult<K>

The result indicating the success and failure details of the operation.

Returns

bool

True if all items were deleted successfully; otherwise, false.

Type Parameters

T

The type of the data elements.

K

The type of the identifier for the data elements.

Exceptions

ArgumentNullException

Thrown when helper or instances is null.