共用方式為


IVsDataViewHierarchy.DelayInsertItem 方法 (String, String, Int32, array<Object[])

如果父節點未展開也不會建立,將指定的節點加入至之後插入的節點佇列。 否則,會立即插入指定的節點。

命名空間:  Microsoft.VisualStudio.Data.Services.SupportEntities
組件:  Microsoft.VisualStudio.Data.Services (在 Microsoft.VisualStudio.Data.Services.dll 中)

語法

'宣告
Function DelayInsertItem ( _
    parentFullName As String, _
    typeName As String, _
    newItemId As Integer, _
    identifier As Object() _
) As Boolean
bool DelayInsertItem(
    string parentFullName,
    string typeName,
    int newItemId,
    Object[] identifier
)
bool DelayInsertItem(
    String^ parentFullName, 
    String^ typeName, 
    int newItemId, 
    array<Object^>^ identifier
)
abstract DelayInsertItem : 
        parentFullName:string * 
        typeName:string * 
        newItemId:int * 
        identifier:Object[] -> bool
function DelayInsertItem(
    parentFullName : String, 
    typeName : String, 
    newItemId : int, 
    identifier : Object[]
) : boolean

參數

  • parentFullName
    類型:String

    新節點的父代的完整名稱。

  • typeName
    類型:String

    新的節點型別的名稱。

  • newItemId
    類型:Int32

    新節點的數值識別項可以插入。

  • identifier
    類型:array<Object[]

    包含表示新結構的識別組件的陣列。

傳回值

類型:Boolean
true ,如果立即插入新節點, false ,如果新的節點會延遲插入的佇列中的位置或沒有立即插入。

例外狀況

例外狀況 條件
ArgumentNullException

parentFullName 或 typeName 參數為 nullnull 參考 (即 Visual Basic 中的 Nothing)。

備註

這個方法會改善效能,因為插入新節點,只有當父展開節點時,以降低樹狀結構中執行之列舉型別的數目。

.NET Framework 安全性

請參閱

參考

IVsDataViewHierarchy 介面

DelayInsertItem 多載

Microsoft.VisualStudio.Data.Services.SupportEntities 命名空間