C# 클래스 System.ComponentModel.Design.Serialization.MemberRelationshipService

A member relationship service is used by a serializer to announce that one property is related to a property on another object. Consider a code based serialization scheme where code is of the following form: object1.Property1 = object2.Property2 Upon interpretation of this code, Property1 on object1 will be set to the return value of object2.Property2. But the relationship between these two objects is lost. Serialization schemes that wish to maintain this relationship may install a MemberRelationshipService into the serialization manager. When an object is deserialized this serivce will be notified of these relationships. It is up to the service to act on these notifications if it wishes. During serialization, the service is also consulted. If a relationship exists the same relationship is maintained by the serializer.
파일 보기 프로젝트 열기: dotnet/corefx 1 사용 예제들

공개 메소드들

메소드 설명
SupportsRelationship ( MemberRelationship source, MemberRelationship relationship ) : bool

Returns true if the provided relatinoship is supported.

보호된 메소드들

메소드 설명
GetRelationship ( MemberRelationship source ) : MemberRelationship

This is the implementation API for returning relationships. The default implementation stores the relationship in a table. Relationships are stored weakly, so they do not keep an object alive.

SetRelationship ( MemberRelationship source, MemberRelationship relationship ) : void

This is the implementation API for returning relationships. The default implementation stores the relationship in a table. Relationships are stored weakly, so they do not keep an object alive. Empty can be passed in for relationship to remove the relationship.

비공개 메소드들

메소드 설명
this ( MemberRelationship source ) : MemberRelationship
this ( object sourceOwner, MemberDescriptor sourceMember ) : MemberRelationship

메소드 상세

GetRelationship() 보호된 메소드

This is the implementation API for returning relationships. The default implementation stores the relationship in a table. Relationships are stored weakly, so they do not keep an object alive.
protected GetRelationship ( MemberRelationship source ) : MemberRelationship
source MemberRelationship
리턴 MemberRelationship

SetRelationship() 보호된 메소드

This is the implementation API for returning relationships. The default implementation stores the relationship in a table. Relationships are stored weakly, so they do not keep an object alive. Empty can be passed in for relationship to remove the relationship.
protected SetRelationship ( MemberRelationship source, MemberRelationship relationship ) : void
source MemberRelationship
relationship MemberRelationship
리턴 void

SupportsRelationship() 공개 추상적인 메소드

Returns true if the provided relatinoship is supported.
public abstract SupportsRelationship ( MemberRelationship source, MemberRelationship relationship ) : bool
source MemberRelationship
relationship MemberRelationship
리턴 bool