Table of Contents

Method Get

Namespace
Innova.Data.Entity
Assembly
Innova.Data.dll

Get<TResult>(IPropertyValues, CancellationToken)

Retrieves a single entity from the database based on the provided property values.

protected virtual Task<TResult> Get<TResult>(IPropertyValues propertyValues, CancellationToken cancellationToken = default) where TResult : class

Parameters

propertyValues IPropertyValues

The property values of the entity.

cancellationToken CancellationToken

The cancellation token.

Returns

Task<TResult>

The retrieved entity.

Type Parameters

TResult

The type of the entity to retrieve.

Get<TResult>(IPrimaryKey, CancellationToken)

Retrieves a single entity from the database based on the provided primary keys.

protected virtual Task<TResult> Get<TResult>(IPrimaryKey keys, CancellationToken cancellationToken = default) where TResult : class

Parameters

keys IPrimaryKey

The primary keys of the entity.

cancellationToken CancellationToken

The cancellation token.

Returns

Task<TResult>

The retrieved entity.

Type Parameters

TResult

The type of the entity to retrieve.

Get(IPrimaryKey, CancellationToken)

Retrieves a single entity from the database based on the provided primary keys.

public virtual Task<T> Get(IPrimaryKey keys, CancellationToken cancellationToken = default)

Parameters

keys IPrimaryKey

The primary keys of the entity.

cancellationToken CancellationToken

The cancellation token.

Returns

Task<T>

The retrieved entity.