ElementTool 类

DomainClass ElementTool 定义为生成元素的工具。

继承层次结构

System.Object
  Microsoft.VisualStudio.Modeling.ModelElement
    Microsoft.VisualStudio.Modeling.DslDefinition.DomainElement
      Microsoft.VisualStudio.Modeling.DslDefinition.Tool
        Microsoft.VisualStudio.Modeling.DslDefinition.ElementTool

命名空间:  Microsoft.VisualStudio.Modeling.DslDefinition
程序集:  Microsoft.VisualStudio.Modeling.Sdk.DslDefinition.12.0(在 Microsoft.VisualStudio.Modeling.Sdk.DslDefinition.12.0.dll 中)

语法

声明
<ValidationStateAttribute(ValidationState.Enabled)> _
<DisplayNameResourceAttribute("Microsoft.VisualStudio.Modeling.DslDefinition.ElementTool.DisplayName",  _
    GetType(DslDefinitionModelDomainModel), "Microsoft.VisualStudio.Modeling.DslDefinition.GeneratedCode.DomainModelResx")> _
<DescriptionResourceAttribute("Microsoft.VisualStudio.Modeling.DslDefinition.ElementTool.Description",  _
    GetType(DslDefinitionModelDomainModel), "Microsoft.VisualStudio.Modeling.DslDefinition.GeneratedCode.DomainModelResx")> _
<DomainModelOwnerAttribute(GetType(DslDefinitionModelDomainModel))> _
<CLSCompliantAttribute(True)> _
<DomainObjectIdAttribute("1cabb513-865b-4ecb-be39-088668ae9607")> _
Public NotInheritable Class ElementTool _
    Inherits Tool
[ValidationStateAttribute(ValidationState.Enabled)]
[DisplayNameResourceAttribute("Microsoft.VisualStudio.Modeling.DslDefinition.ElementTool.DisplayName", 
    typeof(DslDefinitionModelDomainModel), "Microsoft.VisualStudio.Modeling.DslDefinition.GeneratedCode.DomainModelResx")]
[DescriptionResourceAttribute("Microsoft.VisualStudio.Modeling.DslDefinition.ElementTool.Description", 
    typeof(DslDefinitionModelDomainModel), "Microsoft.VisualStudio.Modeling.DslDefinition.GeneratedCode.DomainModelResx")]
[DomainModelOwnerAttribute(typeof(DslDefinitionModelDomainModel))]
[CLSCompliantAttribute(true)]
[DomainObjectIdAttribute("1cabb513-865b-4ecb-be39-088668ae9607")]
public sealed class ElementTool : Tool

ElementTool 类型公开以下成员。

构造函数

  名称 说明
公共方法 ElementTool(Partition, array<PropertyAssignment[]) 构造函数
公共方法 ElementTool(Store, array<PropertyAssignment[]) 构造函数

页首

属性

  名称 说明
公共属性 Caption 获取或设置 Caption 域属性的值。工具的标题在 UI 中显示。 (继承自 Tool。)
公共属性 Class 获取或设置“类”。工具生成的类元素。
公共属性 HelpKeyword 获取或设置 HelpKeyword 域属性的值。用以索引工具 F1 帮助的可选关键字。 (继承自 Tool。)
公共属性 Id 获取元素的 ID。 (继承自 ModelElement。)
公共属性 IsActive 获取 IsActive 标志并验证该元素是否处于活动状态。 (继承自 ModelElement。)
公共属性 IsCaptionTracking 获取或设置 IsCaptionTracking 域属性的值。如果为 true,标题属性跟踪在 DSL 定义的其他数据。 (继承自 Tool。)
公共属性 IsDeleted 获取 IsDeleted 标志并检查该元素是否已从该模型中删除。 (继承自 ModelElement。)
公共属性 IsDeleting 获取 IsDeleting 标志并验证该元素是否正在从该模型中删除。 (继承自 ModelElement。)
公共属性 IsHelpKeywordTracking 获取或设置 IsHelpKeywordTracking 域属性的值。如果为 true,HelpKeyword 属性跟踪在 DSL 定义的其他数据。 (继承自 Tool。)
公共属性 IsTooltipTracking 获取或设置 IsTooltipTracking 域属性的值。如果为 true,Tooltip 属性跟踪在 DSL 定义的其他数据。 (继承自 Tool。)
公共属性 Name 获取或设置姓名域属性的值。用来引用的工具名称。 (继承自 Tool。)
公共属性 Notes 获取或设置注释域属性的值。非正式说明关联的元素。 (继承自 DomainElement。)
公共属性 Partition 获取或设置包含元素的 Partition。 (继承自 ModelElement。)
公共属性 Store 获取包含元素的 Store。 (继承自 ModelElement。)
公共属性 ToolboxIcon 获取或设置 ToolboxIcon 域属性的值。在该工具的工具箱中显示的相对文件路径。 (继承自 Tool。)
公共属性 ToolboxTab 获取或设置 ToolboxTab。工具箱选项卡定义工具。 (继承自 Tool。)
公共属性 Tooltip 获取或设置 Tooltip 域属性的值。用于工具提示的文本。 (继承自 Tool。)

页首

方法

  名称 说明
公共方法 Copy() 创建模型中元素的副本。 (继承自 ModelElement。)
公共方法 Copy(IEnumerable<Guid>) 创建此元素的复制品、其子链接以及元素。 (继承自 ModelElement。)
公共方法 Delete() 从模型中删除元素。 (继承自 ModelElement。)
公共方法 Delete(array<Guid[]) 从模型中删除元素。 (继承自 ModelElement。)
公共方法 Equals 确定指定的对象是否等于当前对象。 (继承自 Object。)
公共方法 GetDomainClass 获取该元素派生度最高的域类。 (继承自 ModelElement。)
公共方法 GetHashCode 作为默认哈希函数。 (继承自 Object。)
公共方法 GetType 获取当前实例的 Type。 (继承自 Object。)
受保护的方法 OnCopy 当此元素已创建为另一个元素的副本时调用。 (继承自 ModelElement。)
受保护的方法 OnDeleted 当已从该模型中删除此元素时调用。 (继承自 ModelElement。)
受保护的方法 OnDeleting 当此元素将要被删除时调用。 (继承自 ModelElement。)
受保护的方法 OnResurrected 当此元素已添加回一个模型时调用。 (继承自 ModelElement。)
受保护的方法 OnRolePlayerPositionChanged 在角色的位置发生更改时调用。 (继承自 ModelElement。)
受保护的方法 OnRolePlayerPositionChanging 当角色扮演者位置将更改时调用。 (继承自 ModelElement。)
公共方法 ToString 返回表示当前对象的字符串。 (继承自 Object。)

页首

扩展方法 

  名称 说明
公共扩展方法 AddExtension(Guid) 已重载。 用被标识的域类型的一新的实例扩展此 ModelElement。如果元素已具有该类型的扩展名,则将引发 InvalidOperationException。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 AddExtension(Type) 已重载。 用指定类型的一新的实例扩展此 ModelElement。如果元素已具有该类型的扩展名,则将引发 InvalidOperationException。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 AddExtension(DomainClassInfo) 已重载。 用指定域类型的一新的实例扩展此 ModelElement。如果元素已具有该类型的扩展名,则将引发 InvalidOperationException。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 AddExtension(ExtensionElement) 已重载。 用一指定的扩展 扩展此 ModelElement。如果元素已具有相同类型的扩展名,则将引发 InvalidOperationException。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 AddExtension<T>() 已重载。 用特定类型的一新的实例扩展此 ModelElement。如果元素已具有相同类型的扩展名,则将引发 InvalidOperationException。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 CanDelete 从模型中删除元素。 (由 ImmutabilityExtensionMethods 定义。)
公共扩展方法 GetAllExtensions 横跨嵌入在该 ModelElement 的扩展元素树来返回执行广度优先遍历的可枚举。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 GetBaseElement 返回指定的 ModelElement 参与的虚拟 MEL 根。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 GetExtension(Guid) 已重载。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 GetExtension(Type) 已重载。 从此 ModelElement 可用扩展中获取指定类型的 ExtensionElement。如果该元素没有此类扩展名,则将引发 InvalidOperationException。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 GetExtension(DomainClassInfo) 已重载。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 GetExtension<T>() 已重载。 从此 ModelElement 可用扩展中获取指定类型的 ExtensionElement。如果该元素没有此类扩展名,则将引发 InvalidOperationException。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 GetLocks 获取此元素的锁定标识。这将包括可在分区包含元素中启用的任何锁。 (由 ImmutabilityExtensionMethods 定义。)
公共扩展方法 IsExtendedBy(Guid) 已重载。 询问该 ModelElement 当前是否由特定类型的 ExtensionElement 扩展。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 IsExtendedBy(Type) 已重载。 询问该 ModelElement 当前是否由特定类型的 ExtensionElement 扩展。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 IsExtendedBy(DomainClassInfo) 已重载。 询问该 ModelElement 当前是否由特定类型的 ExtensionElement 扩展。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 IsLocked 测试此元素是否存在一组指定的锁 (由 ImmutabilityExtensionMethods 定义。)
公共扩展方法 RemoveExtension(Type) 已重载。 移除属于特殊类型的该 ModelElement 的扩展名。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 RemoveExtension(Guid) 已重载。 移除属于特殊类型的指定 ModelElement 的扩展名。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 RemoveExtension(DomainClassInfo) 已重载。 移除属于特殊类型的指定 ModelElement 的扩展名。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 RemoveExtension(ExtensionElement) 已重载。 从该 ModelElement 的扩展移除指定的 ExtensionElement。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 SetLocks 设置此元素的锁定标识 (由 ImmutabilityExtensionMethods 定义。)
公共扩展方法 TryGetExtension(Guid) 已重载。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 TryGetExtension(Type) 已重载。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 TryGetExtension(DomainClassInfo) 已重载。 (由 ModelElementExtensionMethods 定义。)
公共扩展方法 TryGetExtension<T>() 已重载。 从此 ModelElement 可用扩展中获取指定类型的 ExtensionElement。如果钙元素没有此扩展,则结果为 NULL 。 (由 ModelElementExtensionMethods 定义。)

页首

字段

  名称 说明
公共字段静态成员 DomainClassId ElementTool 域类 ID。

页首

显式接口实现  

  名称 说明
显式接口实现私有方法 IMergeElements.CanMerge 如果该元素可已与原型的内容合并则返回 true。 (继承自 ModelElement。)
显式接口实现私有方法 IMergeElements.ChooseMergeTarget(ElementGroup) (继承自 ModelElement。)
显式接口实现私有方法 IMergeElements.ChooseMergeTarget(ElementGroupPrototype) (继承自 ModelElement。)
显式接口实现私有方法 IMergeElements.MergeConfigure (继承自 ModelElement。)
显式接口实现私有方法 IMergeElements.MergeDisconnect (继承自 ModelElement。)
显式接口实现私有方法 IMergeElements.MergeRelate (继承自 ModelElement。)

页首

线程安全

此类型的任何公共 static(在 Visual Basic 中为 Shared) 成员都是线程安全的。但不保证所有实例成员都是线程安全的。

请参阅

参考

Microsoft.VisualStudio.Modeling.DslDefinition 命名空间