EntityTraits(Func<TEntity, TPrimaryKey>, Action<TEntity, TPrimaryKey>, Func<TEntity, Boolean>) Constructor
Initializes a new instance of the EntityTraits<TEntity, TPrimaryKey> class.
Namespace: DevExpress.Mvvm.Utils
Assembly: DevExpress.Mvvm.v24.2.DataModel.dll
NuGet Package: DevExpress.Scaffolding.Core
Declaration
public EntityTraits(
Func<TEntity, TPrimaryKey> getPrimaryKeyFunction,
Action<TEntity, TPrimaryKey> setPrimaryKeyAction,
Func<TEntity, bool> hasPrimaryKeyFunction
)
Parameters
Name | Type | Description |
---|---|---|
getPrimaryKeyFunction | Func<TEntity, TPrimaryKey> | A function that returns the primary key value of a given entity. |
setPrimaryKeyAction | Action<TEntity, TPrimaryKey> | An action that assigns the primary key value to a given entity. |
hasPrimaryKeyFunction | Func<TEntity, Boolean> | A function that determines whether given the entity has a primary key assigned. |
See Also