-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Expand file tree
/
Copy pathIVsaCodeItem.xml
More file actions
221 lines (199 loc) · 13 KB
/
Copy pathIVsaCodeItem.xml
File metadata and controls
221 lines (199 loc) · 13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
<Type Name="IVsaCodeItem" FullName="Microsoft.Vsa.IVsaCodeItem">
<TypeSignature Language="C#" Value="public interface IVsaCodeItem : Microsoft.Vsa.IVsaItem" />
<TypeSignature Language="ILAsm" Value=".class public interface auto ansi abstract IVsaCodeItem implements class Microsoft.Vsa.IVsaItem" />
<TypeSignature Language="DocId" Value="T:Microsoft.Vsa.IVsaCodeItem" />
<TypeSignature Language="VB.NET" Value="Public Interface IVsaCodeItem
Implements IVsaItem" />
<TypeSignature Language="F#" Value="type IVsaCodeItem = interface
 interface IVsaItem" />
<TypeSignature Language="C++ CLI" Value="public interface class IVsaCodeItem : Microsoft::Vsa::IVsaItem" />
<AssemblyInfo>
<AssemblyName>Microsoft.Vsa</AssemblyName>
<AssemblyVersion>7.0.5000.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
</AssemblyInfo>
<Interfaces>
<Interface>
<InterfaceName>Microsoft.Vsa.IVsaItem</InterfaceName>
</Interface>
</Interfaces>
<Attributes>
<Attribute>
<AttributeName Language="C#">[System.Runtime.InteropServices.Guid("E0C0FFE7-7eea-4ee5-b7e4-0080c7eb0b74")]</AttributeName>
<AttributeName Language="F#">[<System.Runtime.InteropServices.Guid("E0C0FFE7-7eea-4ee5-b7e4-0080c7eb0b74")>]</AttributeName>
</Attribute>
<Attribute>
<AttributeName Language="C#">[System.Runtime.InteropServices.InterfaceType(System.Runtime.InteropServices.ComInterfaceType.InterfaceIsIUnknown)]</AttributeName>
<AttributeName Language="F#">[<System.Runtime.InteropServices.InterfaceType(System.Runtime.InteropServices.ComInterfaceType.InterfaceIsIUnknown)>]</AttributeName>
</Attribute>
<Attribute FrameworkAlternate="netframework-2.0;netframework-3.0;netframework-3.5">
<AttributeName Language="C#">[System.Obsolete("Use of this type is not recommended because it is being deprecated in Visual Studio 2005; there will be no replacement for this feature. Please see the ICodeCompiler documentation for additional help.")]</AttributeName>
<AttributeName Language="F#">[<System.Obsolete("Use of this type is not recommended because it is being deprecated in Visual Studio 2005; there will be no replacement for this feature. Please see the ICodeCompiler documentation for additional help.")>]</AttributeName>
</Attribute>
</Attributes>
<Docs>
<summary>Represents a code item to be compiled by the script engine.</summary>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
The specified code item can contain classes, modules, or other source text.
No permissions are required for calling any members of the IVsaCodeItem interface.
The script engine implements this interface in order to add code items.
]]></format>
</remarks>
</Docs>
<Members>
<Member MemberName="AddEventSource">
<MemberSignature Language="C#" Value="public void AddEventSource (string eventSourceName, string eventSourceType);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig newslot virtual instance void AddEventSource(string eventSourceName, string eventSourceType) cil managed" />
<MemberSignature Language="DocId" Value="M:Microsoft.Vsa.IVsaCodeItem.AddEventSource(System.String,System.String)" />
<MemberSignature Language="VB.NET" Value="Public Sub AddEventSource (eventSourceName As String, eventSourceType As String)" />
<MemberSignature Language="F#" Value="abstract member AddEventSource : string * string -> unit" Usage="iVsaCodeItem.AddEventSource (eventSourceName, eventSourceType)" />
<MemberSignature Language="C++ CLI" Value="public:
 void AddEventSource(System::String ^ eventSourceName, System::String ^ eventSourceType);" />
<MemberType>Method</MemberType>
<AssemblyInfo>
<AssemblyName>Microsoft.Vsa</AssemblyName>
<AssemblyVersion>7.0.5000.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Void</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="eventSourceName" Type="System.String" />
<Parameter Name="eventSourceType" Type="System.String" />
</Parameters>
<Docs>
<param name="eventSourceName">A programmatic name of the event source.</param>
<param name="eventSourceType">The type name of the event source.</param>
<summary>Adds an event source to the code item. The code item uses the event source to hook up an event to the named event source by calling the IVsaSite.GetEventSourceInstance method, which is implemented by the host.</summary>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
The script engine uses information provided by the AddEventSource method to hook up events to the named event source. It obtains event sources by calling the IVsaSite.GetEventSourceInstance method, which is implemented by the host. The AddEventSource method creates a class that handles events raised by a host-provided object.
> [!NOTE]
> The JScript .NET script engine does not support this method. In cases where the JScript .NET engine must hook up an event, you must do so using a global item. Rather than event sources, the JScript .NET engine uses AppGlobal item types. For more information, see VsaItemType.
Within the code item, you can access the event source object by name, and, once accessed, you can write event handlers against the object. The event source type is passed as a string rather than as a Type object to facilitate implementing event sources by unmanaged hosts.
The compiler uses the eventSourceType parameter to bind to methods provided by the type. It is also used later when the script engine calls the IVsaSite.GetEventSourceInstance method to request an instance of the Type object.
For more information about the mechanisms for hooking up events for the script engine, see the IVsaSite.GetEventSourceInstance method.
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="AppendSourceText">
<MemberSignature Language="C#" Value="public void AppendSourceText (string text);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig newslot virtual instance void AppendSourceText(string text) cil managed" />
<MemberSignature Language="DocId" Value="M:Microsoft.Vsa.IVsaCodeItem.AppendSourceText(System.String)" />
<MemberSignature Language="VB.NET" Value="Public Sub AppendSourceText (text As String)" />
<MemberSignature Language="F#" Value="abstract member AppendSourceText : string -> unit" Usage="iVsaCodeItem.AppendSourceText text" />
<MemberSignature Language="C++ CLI" Value="public:
 void AppendSourceText(System::String ^ text);" />
<MemberType>Method</MemberType>
<AssemblyInfo>
<AssemblyName>Microsoft.Vsa</AssemblyName>
<AssemblyVersion>7.0.5000.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Void</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="text" Type="System.String" />
</Parameters>
<Docs>
<param name="text">The text to be appended to the code item.</param>
<summary>Appends specified text to the end of the code item.</summary>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
Appended source text is not subjected to validation. For this reason, errors, if any, will surface on the next call to the IVsaEngine.Compile method.
The appended source text is provided as a single string. Should the string require any formatting, you must provide this yourself.
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="CodeDOM">
<MemberSignature Language="C#" Value="public System.CodeDom.CodeObject CodeDOM { get; }" />
<MemberSignature Language="ILAsm" Value=".property instance class System.CodeDom.CodeObject CodeDOM" />
<MemberSignature Language="DocId" Value="P:Microsoft.Vsa.IVsaCodeItem.CodeDOM" />
<MemberSignature Language="VB.NET" Value="Public ReadOnly Property CodeDOM As CodeObject" />
<MemberSignature Language="F#" Value="member this.CodeDOM : System.CodeDom.CodeObject" Usage="Microsoft.Vsa.IVsaCodeItem.CodeDOM" />
<MemberSignature Language="C++ CLI" Value="public:
 property System::CodeDom::CodeObject ^ CodeDOM { System::CodeDom::CodeObject ^ get(); };" />
<MemberType>Property</MemberType>
<AssemblyInfo>
<AssemblyName>Microsoft.Vsa</AssemblyName>
<AssemblyVersion>7.0.5000.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.CodeDom.CodeObject</ReturnType>
</ReturnValue>
<Docs>
<summary>Gets the code document object model (CodeDOM) represented in the code item.</summary>
<value>The CodeDOM for the code item.</value>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
The CodeDOM property is typically generated as part of the compilation step of the script engine, so it is not available until after a call to the IVsaEngine.Compile method. Some VSA implementations may be able to provide the CodeDOM dynamically, without the need for an explicit compilation step, but hosts cannot rely on this behavior. Some script engines, for example, the JScript .NET script engine, do not support this behavior.
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="RemoveEventSource">
<MemberSignature Language="C#" Value="public void RemoveEventSource (string eventSourceName);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig newslot virtual instance void RemoveEventSource(string eventSourceName) cil managed" />
<MemberSignature Language="DocId" Value="M:Microsoft.Vsa.IVsaCodeItem.RemoveEventSource(System.String)" />
<MemberSignature Language="VB.NET" Value="Public Sub RemoveEventSource (eventSourceName As String)" />
<MemberSignature Language="F#" Value="abstract member RemoveEventSource : string -> unit" Usage="iVsaCodeItem.RemoveEventSource eventSourceName" />
<MemberSignature Language="C++ CLI" Value="public:
 void RemoveEventSource(System::String ^ eventSourceName);" />
<MemberType>Method</MemberType>
<AssemblyInfo>
<AssemblyName>Microsoft.Vsa</AssemblyName>
<AssemblyVersion>7.0.5000.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Void</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="eventSourceName" Type="System.String" />
</Parameters>
<Docs>
<param name="eventSourceName">The programmatic name of the event source to be removed.</param>
<summary>Removes the specified event source from the code item.</summary>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
Removing an event source does not remove the underlying event handler from source text. Rather, events no longer raise notifications to the event handler. Therefore, you will get a compiler error if you delete an event source but leave the underlying function in the source code.
]]></format>
</remarks>
</Docs>
</Member>
<Member MemberName="SourceText">
<MemberSignature Language="C#" Value="public string SourceText { get; set; }" />
<MemberSignature Language="ILAsm" Value=".property instance string SourceText" />
<MemberSignature Language="DocId" Value="P:Microsoft.Vsa.IVsaCodeItem.SourceText" />
<MemberSignature Language="VB.NET" Value="Public Property SourceText As String" />
<MemberSignature Language="F#" Value="member this.SourceText : string with get, set" Usage="Microsoft.Vsa.IVsaCodeItem.SourceText" />
<MemberSignature Language="C++ CLI" Value="public:
 property System::String ^ SourceText { System::String ^ get(); void set(System::String ^ value); };" />
<MemberType>Property</MemberType>
<AssemblyInfo>
<AssemblyName>Microsoft.Vsa</AssemblyName>
<AssemblyVersion>7.0.5000.0</AssemblyVersion>
<AssemblyVersion>8.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.String</ReturnType>
</ReturnValue>
<Docs>
<summary>Gets or sets the text of a specified code item, including auto-generated code, if any.</summary>
<value>The source text of the code item.</value>
<remarks>
<format type="text/markdown"><![CDATA[
## Remarks
When you set this property, the text is not subjected to validation. For this reason, errors, if any, will surface on the next call to the IVsaEngine.Compile method.
The SourceText property returns the source text in one large string, including formatting characters such as carriage returns.
To get this property the engine must not be closed. To set this property the engine must not be closed, and the engine must not be running.
]]></format>
</remarks>
</Docs>
</Member>
</Members>
</Type>