EntityReference<TEntity>.Load Method
Namespace:
System.Data.Entity.Core.Objects.DataClasses
Assembly: EntityFramework (in EntityFramework.dll)
Name | Description | |
---|---|---|
![]() | Load() | Loads the related object or objects into the related end with the default merge option.(Inherited from RelatedEnd.) |
![]() | Load(MergeOption) | Loads the related object for this EntityReference<TEntity> with the specified merge option.(Overrides RelatedEnd.Load(MergeOption).) |
EntityReference<TEntity>.Load Method (MergeOption)
Loads the related object for this EntityReference<TEntity> with the specified merge option.
Parameters
- mergeOption
-
Type:
System.Data.Entity.Core.Objects.MergeOption
Specifies how the object should be returned if it already exists in the ObjectContext .
Implements
IRelatedEnd.Load(MergeOption)Exception | Condition |
---|---|
InvalidOperationException | The source of the EntityReference<TEntity> is null or a query returned more than one related end or a query returned zero related ends, and one related end was expected. |