RequiresProvidesDirectiveProcessor.StartProcessingRun 方法
启动指令处理器。
命名空间: Microsoft.VisualStudio.TextTemplating
程序集: Microsoft.VisualStudio.TextTemplating.11.0(在 Microsoft.VisualStudio.TextTemplating.11.0.dll 中)
语法
声明
Public Overrides Sub StartProcessingRun ( _
languageProvider As CodeDomProvider, _
templateContents As String, _
errors As CompilerErrorCollection _
)
public override void StartProcessingRun(
CodeDomProvider languageProvider,
string templateContents,
CompilerErrorCollection errors
)
public:
virtual void StartProcessingRun(
CodeDomProvider^ languageProvider,
String^ templateContents,
CompilerErrorCollection^ errors
) override
abstract StartProcessingRun :
languageProvider:CodeDomProvider *
templateContents:string *
errors:CompilerErrorCollection -> unit
override StartProcessingRun :
languageProvider:CodeDomProvider *
templateContents:string *
errors:CompilerErrorCollection -> unit
public override function StartProcessingRun(
languageProvider : CodeDomProvider,
templateContents : String,
errors : CompilerErrorCollection
)
参数
- languageProvider
类型:System.CodeDom.Compiler.CodeDomProvider
创建已生成转换类的代码生成器。
- templateContents
类型:System.String
所处理的模板的内容。
- errors
类型:System.CodeDom.Compiler.CompilerErrorCollection
一个集合,如果需要,RequiresProvidesDirectiveProcessor 可向该集合添加错误和警告。
实现
IDirectiveProcessor.StartProcessingRun(CodeDomProvider, String, CompilerErrorCollection)
异常
异常 | 条件 |
---|---|
ArgumentNullException | languageProvider 为 nullnull 引用(在 Visual Basic 中为 Nothing)。 |
InvalidOperationException | 处理运行已开始但尚未完成。 |
备注
默认语言提供程序为 CSharpCodeProvider。
.NET Framework 安全性
- 对直接调用方的完全信任。此成员不能由部分信任的代码使用。有关更多信息,请参见通过部分受信任的代码使用库。
请参见
参考
RequiresProvidesDirectiveProcessor 类
Microsoft.VisualStudio.TextTemplating 命名空间
StartProcessingRun