Bagikan melalui


RequiresProvidesDirectiveProcessor.Initialize Method

Initializes an instance of the directive processor.

Namespace:  Microsoft.VisualStudio.TextTemplating
Assembly:  Microsoft.VisualStudio.TextTemplating.10.0 (in Microsoft.VisualStudio.TextTemplating.10.0.dll)

Syntax

'Declaration
Public Overrides Sub Initialize ( _
    host As ITextTemplatingEngineHost _
)
public override void Initialize(
    ITextTemplatingEngineHost host
)
public:
virtual void Initialize(
    ITextTemplatingEngineHost^ host
) override
abstract Initialize : 
        host:ITextTemplatingEngineHost -> unit 
override Initialize : 
        host:ITextTemplatingEngineHost -> unit 
public override function Initialize(
    host : ITextTemplatingEngineHost
)

Parameters

Exceptions

Exception Condition
ArgumentNullException

host is nulla null reference (Nothing in Visual Basic).

Remarks

Initialize(ITextTemplatingEngineHost, CompilerErrorCollection) is called before StartProcessingRun(CodeDomProvider) and lets the directive processor get information that it needs from the host.

You can throw an exception during Initialize(ITextTemplatingEngineHost, CompilerErrorCollection) to stop the processing.

.NET Framework Security

See Also

Reference

RequiresProvidesDirectiveProcessor Class

Microsoft.VisualStudio.TextTemplating Namespace

Initialize(ITextTemplatingEngineHost, CompilerErrorCollection)

ITextTemplatingEngineHost

StartProcessingRun(CodeDomProvider)