Esempio n. 1
0
 public static IEnumerable <object> FindPrimaryKeyValues <T>(this DbContext dbContext, T entity)
 => from p in dbContext.FindPrimaryKeyProperties(entity) select entity.GetTypePropertyValueAs(p.Name);
Esempio n. 2
0
 public static IEnumerable <string> FindPrimaryKeyNames <T>(this DbContext dbContext, T entity)
 => from p in dbContext.FindPrimaryKeyProperties(entity) select p.Name;