Provides an ID that identifies a call to the directive processor.
Namespace: Microsoft.VisualStudio.TextTemplating
Assembly: Microsoft.VisualStudio.TextTemplating (in Microsoft.VisualStudio.TextTemplating.dll)
Syntax
'宣言
Protected Overridable Function ProvideUniqueId ( _
directiveName As String, _
arguments As IDictionary(Of String, String), _
requiresArguments As IDictionary(Of String, String), _
providesArguments As IDictionary(Of String, String) _
) As String
'使用
Dim directiveName As String
Dim arguments As IDictionary(Of String, String)
Dim requiresArguments As IDictionary(Of String, String)
Dim providesArguments As IDictionary(Of String, String)
Dim returnValue As String
returnValue = Me.ProvideUniqueId(directiveName, _
arguments, requiresArguments, providesArguments)
protected virtual string ProvideUniqueId(
string directiveName,
IDictionary<string, string> arguments,
IDictionary<string, string> requiresArguments,
IDictionary<string, string> providesArguments
)
protected:
virtual String^ ProvideUniqueId(
String^ directiveName,
IDictionary<String^, String^>^ arguments,
IDictionary<String^, String^>^ requiresArguments,
IDictionary<String^, String^>^ providesArguments
)
protected function ProvideUniqueId(
directiveName : String,
arguments : IDictionary<String, String>,
requiresArguments : IDictionary<String, String>,
providesArguments : IDictionary<String, String>
) : String
Parameters
directiveName
Type: System.StringThe name of the directive.
arguments
Type: System.Collections.Generic.IDictionary<String, String>The arguments that were passed to the ProcessDirective method that is calling this method.
requiresArguments
Type: System.Collections.Generic.IDictionary<String, String>The standard parameters that the directive processor requires.
providesArguments
Type: System.Collections.Generic.IDictionary<String, String>The standard parameters that the directive processor provides.
Return Value
Type: System.String
A String that contains a unique ID for a call to the directive processor.
Remarks
A text template can contain more than one call to the same directive or to different directives in the same directive processor. This method provides a unique ID for each directive call, which the directive processor can use when calling ResolveParameterValue.
Directive processors can use one of their provides parameters to specify the unique ID. The arguments parameters are searched first for the unique ID, and the providesArguments parameters are searched second. If no unique ID is found, directiveName is used as the unique ID.
This method is called by ProcessDirective.
Permissions
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
See Also
Reference
RequiresProvidesDirectiveProcessor Class
RequiresProvidesDirectiveProcessor Members