包含需要重新创建一组元素和链接的信息。 用于存放元素在工具中,在剪贴板以及在拖动操作。
继承层次结构
System.Object
Microsoft.VisualStudio.Modeling.ElementGroupPrototype
命名空间: Microsoft.VisualStudio.Modeling
程序集: Microsoft.VisualStudio.Modeling.Sdk.12.0(在 Microsoft.VisualStudio.Modeling.Sdk.12.0.dll 中)
语法
声明
<SerializableAttribute> _
Public NotInheritable Class ElementGroupPrototype _
Implements ISerializable, IDeserializationCallback
[SerializableAttribute]
public sealed class ElementGroupPrototype : ISerializable,
IDeserializationCallback
ElementGroupPrototype 类型公开以下成员。
构造函数
名称 | 说明 | |
---|---|---|
![]() |
ElementGroupPrototype(ElementGroup, IEnumerable<ModelElement>) | 构造函数 |
![]() |
ElementGroupPrototype(Partition, Guid) | 采用 rool 域类 ID 的构造函数。这用于确定元素是否可合并在父元素下。 |
![]() |
ElementGroupPrototype(Partition, ICollection<ModelElement>, ElementGroup) | 构造函数 |
页首
属性
名称 | 说明 | |
---|---|---|
![]() |
ProtoElementLinks | 获取包含在 ElementGroupPrototype 中的所有 ProtoElementLinks 的集合。 |
![]() |
ProtoElements | 获取包含在 ElementGroupPrototype 中的所有 ProtoElements 的集合。 |
![]() |
RootProtoElements | 获取在 ElementGroupPrototype 中包含的所有根 ProtoElements 的集合。 |
![]() |
SourceContext | 返回此 ElementGroupPrototype 的源 ElementGroupContext 对象 |
![]() |
SourceRootElementIds | 从源上下文中返回根元素 ID 的只读列表 |
![]() |
TargetContext | 返回此 ElementGroupPrototype 的目标 ElementGroupContext 对象 |
![]() |
TargetRootElementIds | 从目标上下文中返回根元素 ID 的只读列表 |
![]() |
TopLevelProtoGroup | 该 ElementGroupPrototype 组原型表示 |
![]() |
UserData | 用户从 outer-most 元素团队定义数据对象 |
页首
方法
名称 | 说明 | |
---|---|---|
![]() |
CanCreateElementGroup(Partition) | 该原型元素团队是否可以在指示的部件中创建上级元素团队的副本? |
![]() |
CanCreateElementGroup(Store) | 该原型元素团队是否可以在指示的存储区中创建上级元素团队的副本? |
![]() |
CanCreateElementGroup(Partition, IElementPartitionMapper) | 该原型元素团队是否可以在指示的部件中创建上级元素团队的副本? |
![]() |
CreateElementGroup(Partition) | 创建上级元素组的副本 |
![]() |
CreateElementGroup(Store) | 创建上级元素组的副本 |
![]() |
CreateElementGroup(Partition, IElementPartitionMapper) | 创建上级元素组的副本 |
![]() |
Equals | 确定指定的对象是否等于当前对象。 (继承自 Object。) |
![]() |
GetHashCode | 作为默认哈希函数。 (继承自 Object。) |
![]() |
GetObjectData | 使用序列化此对象所需的数据来填充序列化信息。 |
![]() |
GetProtoElement | 获取对应指定 ID 的 ProtoElement。 |
![]() |
GetProtoLink | 获取对应指定 ID 的 ProtoLink。 |
![]() |
GetProtoLinks | 返回包含在传递 DomainRoleId 中播放的传递 ProtoElementBase的 ProtoLink 对象的 IList。 |
![]() ![]() |
GetReconstitutedElement | 返回给定源 ModelElement 的 guid 的重建ModelElement。 |
![]() |
GetSourceRootElementId | 获取对应于指定的目标根 ModelElement ID的源根 ModelElement 的 ID。如果未找到它,则返回 Guid.Empty。 |
![]() |
GetType | 获取当前实例的 Type。 (继承自 Object。) |
![]() |
IsInRole | 如果传递的 ProtoElementBase 播放在此 ElementGroupPrototype 中的传递角色,则返回 true。 |
![]() |
ResolveProtoLinks | 解决传递的 ProtoLinks 的 IList 到在传递的 DomainRoleId 播放的 ProtoElements。 |
![]() |
ToString() | 返回表示当前对象的字符串。 (继承自 Object。) |
![]() |
ToString(Partition) | 转储 ElementGroupPrototype 里 Elements 和 ElementLinks 的名称,给定所提供分区的 DomainClass 定义。 |
页首
字段
名称 | 说明 | |
---|---|---|
![]() ![]() |
CreatingKey | 上下文信息搜索的键值 |
![]() ![]() |
DefaultDataFormatName | ElementGroupPrototype 的默认数据格式名称。 |
![]() ![]() |
ElementGroupIdDictionary | 用于针对 Element Id 字典和根元素 (Id) 列表的 TargetContext ElementGroupContext 键值。 |
![]() ![]() |
RootElementIdList | 用于针对 RootElement Id 列表和根元素 (Id) 列表的 Source and Target Context ElementGroupContext 键值。 |
![]() ![]() |
RootElementList | 用于针对 RootElement 列表和根元素列表的 Source and Target Context ElementGroupContext 键值。 |
页首
显式接口实现
名称 | 说明 | |
---|---|---|
![]() ![]() |
IDeserializationCallback.OnDeserialization | 图表完全加载时的反序列化对象 |
页首
备注
包含元素 ElementGroupPrototype (EGP) 和链接模式,可用于创建新组元素和链接在合并操作。 在合并过程,EGP 用于创建 ElementGroup,然后链接到目标模型的元素。
EGPs 用于以下用途:
传播在拖动操作的信息;
存储在剪贴板的信息;
存储对象模式在工具箱中。
有关更多信息,请参见如何:程序复制和粘贴行为 - 重定向和如何:添加拖放处理程序。
线程安全
此类型的任何公共 static(在 Visual Basic 中为 Shared) 成员都是线程安全的。但不保证所有实例成员都是线程安全的。