TreeNodeCollection 成员

表示 TreeNode 对象的集合。

下表列出了由 TreeNodeCollection 类型公开的成员。

公共属性

  名称 说明
Public property Supported by the .NET Compact Framework Count 获取集合中 TreeNode 对象的总数。
Public property Supported by the .NET Compact Framework IsReadOnly 获取一个值,该值指示集合是否为只读。
Public property Supported by the .NET Compact Framework Item 已重载。获取或设置集合中的树节点。

页首

公共方法

(请参见 受保护的方法 )

  名称 说明
Public method Supported by the .NET Compact Framework Add 已重载。 在集合中添加新的树节点。
Public method Supported by the .NET Compact Framework AddRange 将先前创建的一组树节点添加到集合中。
Public method Supported by the .NET Compact Framework Clear 从集合中删除所有树节点。
Public method Supported by the .NET Compact Framework Contains 确定指定的树节点是否为集合的成员。
Public method ContainsKey 确定集合是否包含具有指定键的树节点。
Public method Supported by the .NET Compact Framework CopyTo 将整个集合复制到现有数组中,从该数组内的指定位置开始复制。
Public method Supported by the .NET Compact Framework Equals  已重载。 确定两个 Object 实例是否相等。 (从 Object 继承。)
Public method Find 查找具有指定键的树节点,可以选择搜索子节点。
Public method Supported by the .NET Compact Framework GetEnumerator 返回可用于循环访问树节点集合的枚举数。
Public method Supported by the .NET Compact Framework GetHashCode  用作特定类型的哈希函数。GetHashCode 适合在哈希算法和数据结构(如哈希表)中使用。 (从 Object 继承。)
Public method Supported by the .NET Compact Framework GetType  获取当前实例的 Type。 (从 Object 继承。)
Public method Supported by the .NET Compact Framework IndexOf 返回集合中指定树节点的索引。
Public method IndexOfKey 返回具有指定键的首个树节点的索引。
Public method Supported by the .NET Compact Framework Insert 已重载。 将集合中的一项插入指定位置。
Public method Static Supported by the .NET Compact Framework ReferenceEquals  确定指定的 Object 实例是否是相同的实例。 (从 Object 继承。)
Public method Supported by the .NET Compact Framework Remove 从树节点集合中移除指定的树节点。
Public method Supported by the .NET Compact Framework RemoveAt 从树节点集合的指定索引处移除树节点。
Public method RemoveByKey 从集合中移除具有指定键的树节点。
Public method Supported by the .NET Compact Framework ToString  返回表示当前 ObjectString。 (从 Object 继承。)

页首

受保护的方法

  名称 说明
Protected method Supported by the .NET Compact Framework Finalize  允许 Object 在“垃圾回收”回收 Object 之前尝试释放资源并执行其他清理操作。 (从 Object 继承。)
Protected method Supported by the .NET Compact Framework MemberwiseClone  创建当前 Object 的浅表副本。 (从 Object 继承。)

页首

显式接口实现

  名称 说明
Explicit interface implementation Method Supported by the .NET Compact Framework System.Collections.IList.Add 将对象添加到树节点集合的末尾。
Explicit interface implementation Method Supported by the .NET Compact Framework System.Collections.IList.Contains 确定指定的树节点是否为集合的成员。
Explicit interface implementation Method Supported by the .NET Compact Framework System.Collections.IList.IndexOf 返回集合中指定树节点的索引。
Explicit interface implementation Method Supported by the .NET Compact Framework System.Collections.IList.Insert 在树节点集合中的指定位置插入现有树节点。
Explicit interface implementation Method Supported by the .NET Compact Framework System.Collections.IList.Remove 从树节点集合中移除指定的树节点。
Explicit interface implementation Property Supported by the .NET Compact Framework System.Collections.ICollection.IsSynchronized 获取一个值,该值指示对集合的访问是否为同步的(线程安全)。
Explicit interface implementation Property Supported by the .NET Compact Framework System.Collections.ICollection.SyncRoot 获取可用于同步对集合的访问的对象。
Explicit interface implementation Property Supported by the .NET Compact Framework System.Collections.IList.IsFixedSize 获取一个值,该值指示树节点集合是否具有固定大小。
Explicit interface implementation Property Supported by the .NET Compact Framework System.Collections.IList.Item 获取或设置集合中指定索引处的树节点。

页首

请参见

参考

TreeNodeCollection 类
System.Windows.Forms 命名空间
TreeView
TreeNode 类