将此特性应用与一个包的包类,该包定义了文本模板指令处理器。
此 API 不兼容 CLS。
继承层次结构
System.Object
  System.Attribute
    Microsoft.VisualStudio.Shell.RegistrationAttribute
      Microsoft.VisualStudio.TextTemplating.VSHost.ProvideDirectiveProcessorAttribute
命名空间:  Microsoft.VisualStudio.TextTemplating.VSHost
程序集:  Microsoft.VisualStudio.TextTemplating.VSHost.10.0(在 Microsoft.VisualStudio.TextTemplating.VSHost.10.0.dll 中)
语法
声明
<AttributeUsageAttribute(AttributeTargets.Class, AllowMultiple := True)> _
<CLSCompliantAttribute(False)> _
Public NotInheritable Class ProvideDirectiveProcessorAttribute _
    Inherits RegistrationAttribute
[AttributeUsageAttribute(AttributeTargets.Class, AllowMultiple = true)]
[CLSCompliantAttribute(false)]
public sealed class ProvideDirectiveProcessorAttribute : RegistrationAttribute
[AttributeUsageAttribute(AttributeTargets::Class, AllowMultiple = true)]
[CLSCompliantAttribute(false)]
public ref class ProvideDirectiveProcessorAttribute sealed : public RegistrationAttribute
[<Sealed>]
[<AttributeUsageAttribute(AttributeTargets.Class, AllowMultiple = true)>]
[<CLSCompliantAttribute(false)>]
type ProvideDirectiveProcessorAttribute =  
    class
        inherit RegistrationAttribute
    end
public final class ProvideDirectiveProcessorAttribute extends RegistrationAttribute
ProvideDirectiveProcessorAttribute 类型公开以下成员。
构造函数
| 名称 | 说明 | |
|---|---|---|
| .gif) | ProvideDirectiveProcessorAttribute | 将此特性应用与一个包的包类,该包定义了文本模板指令处理器。 | 
页首
属性
| 名称 | 说明 | |
|---|---|---|
| .gif) | Description | 指令处理器的可读说明 | 
| .gif) | Name | 指令处理器的名称 | 
| .gif) | Type | 实现指令处理器的类型 | 
| .gif) | TypeId | (继承自 RegistrationAttribute。) | 
页首
方法
| 名称 | 说明 | |
|---|---|---|
| .gif) | Equals | 基础结构。返回一个值,该值指示此实例是否与指定的对象相等。 (继承自 Attribute。) | 
| .gif) | Finalize | 允许对象在“垃圾回收”回收之前尝试释放资源并执行其他清理操作。 (继承自 Object。) | 
| .gif) | GetHashCode | 返回此实例的哈希代码。 (继承自 Attribute。) | 
| .gif) | GetPackageRegKeyPath | (继承自 RegistrationAttribute。) | 
| .gif) | GetType | 获取当前实例的 Type。 (继承自 Object。) | 
| .gif) | IsDefaultAttribute | 当在派生类中重写时,指示此实例的值是否是派生类的默认值。 (继承自 Attribute。) | 
| .gif) | Match | 当在派生类中重写时,返回一个指示此实例是否等于指定对象的值。 (继承自 Attribute。) | 
| .gif) | MemberwiseClone | 创建当前 Object 的浅表副本。 (继承自 Object。) | 
| .gif) | Register | 在用户需要安装指令处理器时调用。 (重写 RegistrationAttribute.Register(RegistrationAttribute.RegistrationContext)。) | 
| .gif) | ToString | 返回表示当前对象的字符串。 (继承自 Object。) | 
| .gif) | Unregister | 在用户需要卸载指令处理器时调用。 (重写 RegistrationAttribute.Unregister(RegistrationAttribute.RegistrationContext)。) | 
页首
字段
| 名称 | 说明 | |
|---|---|---|
| .gif) .gif) | DirectiveProcessorsKeyName | 指令处理器的特定注册表项的名称 | 
| .gif) .gif) | TextTemplatingKeyName | 文本模板化的根注册表项的名称 | 
页首
显式接口实现
| 名称 | 说明 | |
|---|---|---|
| .gif) .gif) | _Attribute.GetIDsOfNames | 将一组名称映射为对应的一组调度标识符。 (继承自 Attribute。) | 
| .gif) .gif) | _Attribute.GetTypeInfo | 检索对象的类型信息,然后可以使用该信息获取接口的类型信息。 (继承自 Attribute。) | 
| .gif) .gif) | _Attribute.GetTypeInfoCount | 检索对象提供的类型信息接口的数量(0 或 1)。 (继承自 Attribute。) | 
| .gif) .gif) | _Attribute.Invoke | 提供对某一对象公开的属性和方法的访问。 (继承自 Attribute。) | 
页首
备注
有关更多信息,请参见 创建自定义文本模板指令处理器。
示例
当您创建域特定语言时,此属性在您的 DslPackage 代码中生成。 有关更多信息,请参见 可视化和建模 SDK - 域特定语言。
线程安全
此类型的任何公共 static(在 Visual Basic 中为 Shared) 成员都是线程安全的。但不保证所有实例成员都是线程安全的。