RelatedEnd Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Represents a base class that implements common functionality for a related end.
public ref class RelatedEnd abstract : System::Data::Objects::DataClasses::IRelatedEnd
[System.Runtime.Serialization.DataContract]
[System.Serializable]
public abstract class RelatedEnd : System.Data.Objects.DataClasses.IRelatedEnd
[<System.Runtime.Serialization.DataContract>]
[<System.Serializable>]
type RelatedEnd = class
interface IRelatedEnd
Public MustInherit Class RelatedEnd
Implements IRelatedEnd
- Inheritance
-
RelatedEnd
- Derived
- Attributes
- Implements
Remarks
RelatedEnd is the base class for the EntityCollection<TEntity> class and the EntityReference<TEntity> class.
The RelatedEnd class implements functionality that is shared between the EntityCollection<TEntity> and EntityReference<TEntity> classes.
This class is not intended to be used directly in your code.
Properties
IsLoaded |
Gets a value that indicates whether all related objects have been loaded. |
RelationshipName |
Gets the name of the relationship in which this related end participates. |
RelationshipSet |
Gets a reference to the metadata for the related end. |
SourceRoleName |
Gets the role name at the source end of the relationship. |
TargetRoleName |
Gets the role name at the target end of the relationship. |
Methods
Attach<TEntity>(IEnumerable<TEntity>, Boolean) |
Defines a relationship between two attached objects. |
Equals(Object) |
Determines whether the specified object is equal to the current object. (Inherited from Object) |
GetEnumerator() |
Returns an IEnumerator that iterates through the collection of related objects. |
GetHashCode() |
Serves as the default hash function. (Inherited from Object) |
GetType() |
Gets the Type of the current instance. (Inherited from Object) |
Load() |
When overridden in a derived class, loads the related object or objects into the related end with the default merge option. |
Load(MergeOption) |
When overridden in a derived class, loads an object or objects from the related end with the specified merge option. |
MemberwiseClone() |
Creates a shallow copy of the current Object. (Inherited from Object) |
Merge<TEntity>(IEnumerable<TEntity>, MergeOption, Boolean) |
Merges related entities into the local EntityCollection<TEntity>. |
OnDeserialized(StreamingContext) |
Used internally to deserialize entity objects along with the RelationshipManager instances. |
ToString() |
Returns a string that represents the current object. (Inherited from Object) |
ValidateEntityForAttach<TEntity>(TEntity, Int32, Boolean) |
Determines whether an object can be attached to the local collection or reference. |
ValidateLoad<TEntity>(MergeOption, String) |
Ensures that the related object or objects can be successfully loaded into the local collection or reference. |
ValidateOwnerForAttach() |
Ensures that the object to which the related end belongs supports an attach operation. |
Events
AssociationChanged |
Occurs when a change is made to a related end. |
Explicit Interface Implementations
IRelatedEnd.Add(IEntityWithRelationships) |
Adds an object to the related end. |
IRelatedEnd.Add(Object) |
Adds an object to the related end. |
IRelatedEnd.Attach(IEntityWithRelationships) |
Attaches an object at the related end. |
IRelatedEnd.Attach(Object) |
Attaches an object to the related end. |
IRelatedEnd.CreateSourceQuery() |
Returns an IEnumerable that represents the objects that belong to the related end. |
IRelatedEnd.Remove(IEntityWithRelationships) |
Removes an object from the collection at the related end. |
IRelatedEnd.Remove(Object) |
Removes an object from the related end if the object is part of the related end. |
Applies to
.NET
피드백
https://aka.ms/ContentUserFeedback
출시 예정: 2024년 내내 콘텐츠에 대한 피드백 메커니즘으로 GitHub 문제를 단계적으로 폐지하고 이를 새로운 피드백 시스템으로 바꿀 예정입니다. 자세한 내용은 다음을 참조하세요.다음에 대한 사용자 의견 제출 및 보기