1 implementation of IEntityWithKey
System.Data.Entity (1)
System\Data\Objects\DataClasses\EntityObject.cs (1)
22
public abstract class EntityObject : StructuralObject,
IEntityWithKey
, IEntityWithChangeTracker, IEntityWithRelationships
24 references to IEntityWithKey
System.Data.Entity (24)
System\Data\Common\Internal\Materialization\Translator.cs (4)
554
private static readonly MethodInfo IEntityKeyWithKey_EntityKey = typeof(System.Data.Objects.DataClasses.
IEntityWithKey
).GetProperty("EntityKey").GetSetMethod();
597
private static readonly ConstructorInfo EntityWithKeyStrategy_ctor = typeof(EntityWithKeyStrategy).GetConstructor(new Type[] { typeof(
IEntityWithKey
) });
760
bool isIEntityWithKey = typeof(
IEntityWithKey
).IsAssignableFrom(actualType);
1255
if (typeof(
IEntityWithKey
).IsAssignableFrom(actualType) && MergeOption.AppendOnly != _mergeOption)
System\Data\Metadata\MetadataWorkspace.cs (1)
452
ImplicitLoadAssemblyForType(typeof(System.Data.Objects.DataClasses.
IEntityWithKey
), callingAssembly);
System\Data\Objects\Internal\EntityWithKeyStrategy.cs (2)
21
private
IEntityWithKey
_entity;
27
public EntityWithKeyStrategy(
IEntityWithKey
entity)
System\Data\Objects\Internal\EntityWrapperFactory.cs (6)
87
bool isIEntityWithKey = typeof(
IEntityWithKey
).IsAssignableFrom(entityType);
110
where TEntity : IEntityWithRelationships,
IEntityWithKey
, IEntityWithChangeTracker
146
bool isIEntityWithKey = typeof(
IEntityWithKey
).IsAssignableFrom(entityType);
280
IEntityWithKey
withKey = entity as
IEntityWithKey
;
351
return (object entity) => new EntityWithKeyStrategy((
IEntityWithKey
)entity);
System\Data\Objects\Internal\LightweightEntityWrapper.cs (3)
24
where TEntity : IEntityWithRelationships,
IEntityWithKey
, IEntityWithChangeTracker
38
Debug.Assert(entity is
IEntityWithKey
, "LightweightEntityWrapper only works with entities that implement IEntityWithKey");
61
Debug.Assert(entity is
IEntityWithKey
, "LightweightEntityWrapper only works with entities that implement IEntityWithKey");
System\Data\Objects\ObjectContext.cs (1)
1076
public void Attach(
IEntityWithKey
entity)
System\Data\Objects\ObjectStateManager.cs (7)
1688
Debug.Assert(!(entry.Entity is
IEntityWithKey
), "_keylessEntityStore contains an entry that implement IEntityWithKey");
1720
!(entry.Entity is
IEntityWithKey
))
1745
Debug.Assert(!(entity is
IEntityWithKey
));
2593
IEntityWithKey
entityWithKey = entity as
IEntityWithKey
;
2851
if (null != entry.Entity && !(entry.Entity is
IEntityWithKey
))
2963
if (null != wrappedEntity && null != wrappedEntity.Entity && !(wrappedEntity.Entity is
IEntityWithKey
))