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
    类型:System.String
    新的节点的父节点的全名。
  • newItemId
    类型:System.Int32
    新的节点一个数字标识符插入。
  • identifier
    类型:array<System.Object[]
    包含表示新节点的标识符部件的数组。

返回值

类型:System.Boolean
true if the new node is inserted immediately; false if the new node is placed in queue for delayed insert or is not inserted immediately.

异常

异常 条件
ArgumentNullException

parentFullName 或 typeName 参数为 nullnull 引用(在 Visual Basic 中为 Nothing)。

备注

此方法提高性能,因为插入新的节点,只有在父节点展开后,从而减少在树执行的枚举数。

.NET Framework 安全性

请参见

参考

IVsDataViewHierarchy 接口

DelayInsertItem 重载

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