MemberRelationshipService.SetRelationship 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
在源对象和目标关系之间创建关系。
protected:
virtual void SetRelationship(System::ComponentModel::Design::Serialization::MemberRelationship source, System::ComponentModel::Design::Serialization::MemberRelationship relationship);
protected virtual void SetRelationship (System.ComponentModel.Design.Serialization.MemberRelationship source, System.ComponentModel.Design.Serialization.MemberRelationship relationship);
abstract member SetRelationship : System.ComponentModel.Design.Serialization.MemberRelationship * System.ComponentModel.Design.Serialization.MemberRelationship -> unit
override this.SetRelationship : System.ComponentModel.Design.Serialization.MemberRelationship * System.ComponentModel.Design.Serialization.MemberRelationship -> unit
Protected Overridable Sub SetRelationship (source As MemberRelationship, relationship As MemberRelationship)
参数
- source
- MemberRelationship
源关系。
- relationship
- MemberRelationship
要设置到源中的关系。
例外
服务不支持该关系。
注解
如果关系参数为 Empty,则SetRelationship方法清除任何现有关系。 默认实现使用弱引用将关系存储在字典中,因此关系表不会使对象保持活动状态。