Table of Contents

Method LoadCollectionAsync

Namespace
Kepware.Api.ClientHandler
Assembly
Kepware.Api.dll

LoadCollectionAsync<T>(string?, CancellationToken)

Loads a collection of entities of type T asynchronously by its owner from the Kepware server.

public Task<T?> LoadCollectionAsync<T>(string? owner = null, CancellationToken cancellationToken = default) where T : EntityCollection<DefaultEntity>, new()

Parameters

owner string

The owner of the entity collection.

cancellationToken CancellationToken

A token that can be used to request cancellation of the operation.

Returns

Task<T>

The loaded collection of entities of type T or null if not found.

Type Parameters

T

The type of the entity collection to load.

LoadCollectionAsync<T>(NamedEntity, CancellationToken)

Loads a collection of entities of type T asynchronously by its owner from the Kepware server.

public Task<T?> LoadCollectionAsync<T>(NamedEntity owner, CancellationToken cancellationToken = default) where T : EntityCollection<DefaultEntity>, new()

Parameters

owner NamedEntity

The owner of the entity collection.

cancellationToken CancellationToken

A token that can be used to request cancellation of the operation.

Returns

Task<T>

The loaded collection of entities of type T or null if not found.

Type Parameters

T

The type of the entity collection to load.

LoadCollectionAsync<T, K>(string?, CancellationToken)

Loads a collection of entities of type T asynchronously by its owner from the Kepware server.

public Task<T?> LoadCollectionAsync<T, K>(string? owner = null, CancellationToken cancellationToken = default) where T : EntityCollection<K>, new() where K : BaseEntity, new()

Parameters

owner string

The owner of the entity collection.

cancellationToken CancellationToken

A token that can be used to request cancellation of the operation.

Returns

Task<T>

The loaded collection of entities of type T or null if not found.

Type Parameters

T

The type of the entity collection to load.

K

The type of the entities in the collection.

LoadCollectionAsync<T, K>(NamedEntity, CancellationToken)

Loads a collection of entities of type T asynchronously by its owner from the Kepware server.

public Task<T?> LoadCollectionAsync<T, K>(NamedEntity owner, CancellationToken cancellationToken = default) where T : EntityCollection<K>, new() where K : BaseEntity, new()

Parameters

owner NamedEntity

The owner of the entity collection.

cancellationToken CancellationToken

A token that can be used to request cancellation of the operation.

Returns

Task<T>

The loaded collection of entities of type T or null if not found.

Type Parameters

T

The type of the entity collection to load.

K

The type of the entities in the collection.

LoadCollectionAsync<T, K>(IEnumerable<string>, CancellationToken)

Loads a collection of entities of type T asynchronously by its endpoint from the Kepware server.

public Task<T?> LoadCollectionAsync<T, K>(IEnumerable<string> owner, CancellationToken cancellationToken = default) where T : EntityCollection<K>, new() where K : BaseEntity, new()

Parameters

owner IEnumerable<string>

The owner of the entity collection.

cancellationToken CancellationToken

A token that can be used to request cancellation of the operation.

Returns

Task<T>

The loaded collection of entities of type T or null if not found.

Type Parameters

T

The type of the entity collection to load.

K

The type of the entities in the collection.