CodeTypeReferenceCollection.Insert(Int32, CodeTypeReference) 方法

定义

CodeTypeReference 插入到集合中的指定索引处。

public:
 void Insert(int index, System::CodeDom::CodeTypeReference ^ value);
public void Insert (int index, System.CodeDom.CodeTypeReference value);
member this.Insert : int * System.CodeDom.CodeTypeReference -> unit
Public Sub Insert (index As Integer, value As CodeTypeReference)

参数

index
Int32

从零开始的索引,该项应插入此位置。

value
CodeTypeReference

要插入的 CodeTypeReference

示例

// Inserts a CodeTypeReference at index 0 of the collection.
collection->Insert( 0, gcnew CodeTypeReference( bool::typeid ) );
// Inserts a CodeTypeReference at index 0 of the collection.
collection.Insert( 0, new CodeTypeReference(typeof(bool)) );
' Inserts a CodeTypeReference at index 0 of the collection.
collection.Insert(0, New CodeTypeReference(GetType(Boolean)))

适用于

另请参阅