DesignerRegionCollection 类

定义

表示控件设计器中 DesignerRegion 对象的集合。

public ref class DesignerRegionCollection : System::Collections::IList
public class DesignerRegionCollection : System.Collections.IList
type DesignerRegionCollection = class
    interface IList
    interface ICollection
    interface IEnumerable
Public Class DesignerRegionCollection
Implements IList
继承
DesignerRegionCollection
实现

注解

类和任何派生类都使用 类来包含和枚举设计宿主中 控件的设计器区域,例如 Visual Studio ControlDesigner DesignerRegionCollection 2005。

例如, ControlDesigner.GetDesignTimeHtml 方法可用于定义区域并将其添加到集合中。

使用 Owner 属性访问包含设计器区域集合的控件设计器对象。 使用 DesignerRegionCollection 方法和属性检查和维护 DesignerRegion 集合中的对象。

添加对象时,集合会动态增加。 此集合中的索引从零开始。 使用 Count 属性确定集合中的设计器区域数。 使用 DesignerRegionCollection 成员提供以下功能:

  • Add将单个设计器区域添加到集合的方法。

  • Insert在集合中的特定索引添加设计器区域的方法。

  • Remove用于删除设计器区域的方法。

  • RemoveAt用于移除特定索引的设计器区域的方法。

  • Contains用于确定集合中是否已包含特定设计器区域的方法。

  • IndexOf检索集合中设计器区域索引的方法。

  • 使用 Item[] 数组表示法获取或设置特定索引的设计器区域。

  • Clear 集合中删除所有设计器区域的方法。

构造函数

DesignerRegionCollection()

初始化 DesignerRegionCollection 类的新实例。

DesignerRegionCollection(ControlDesigner)

为指定的控件设计器初始化 DesignerRegionCollection 类的新实例。

属性

Count

获取集合中 DesignerRegion 对象的数量。

IsFixedSize

获取一个值,该值指示 DesignerRegionCollection 对象是否具有固定大小。

IsReadOnly

获取一个值,该值指示 DesignerRegionCollection 对象是否为只读。

IsSynchronized

获取一个值,该值指示对 DesignerRegionCollection 对象的访问是否同步(线程安全)。

Item[Int32]

获取或设置集合中指定索引处的 DesignerRegion 对象。

Owner

获取具有设计器区域集合的控件设计器。

SyncRoot

获取一个对象,该对象可用于同步对 DesignerRegionCollection 对象的访问。

方法

Add(DesignerRegion)

将指定的 DesignerRegion 对象添加到集合末尾。

Clear()

从集合中移除所有区域。

Contains(DesignerRegion)

获取指示集合中是否包含指定区域的值。

CopyTo(Array, Int32)

从特定的 Array 索引开始,将集合的元素复制到 Array 对象。

Equals(Object)

确定指定对象是否等于当前对象。

(继承自 Object)
GetEnumerator()

返回一个循环访问集合的枚举器。

GetHashCode()

作为默认哈希函数。

(继承自 Object)
GetType()

获取当前实例的 Type

(继承自 Object)
IndexOf(DesignerRegion)

返回指定的 DesignerRegion 对象在集合中的索引。

Insert(Int32, DesignerRegion)

DesignerRegion 对象插入到集合中的指定索引处。

MemberwiseClone()

创建当前 Object 的浅表副本。

(继承自 Object)
Remove(DesignerRegion)

从集合中移除指定的 DesignerRegion 对象。

RemoveAt(Int32)

移除集合中指定索引处的 DesignerRegion 对象。

ToString()

返回表示当前对象的字符串。

(继承自 Object)

显式接口实现

ICollection.CopyTo(Array, Int32)

有关此成员的说明,请参见 CopyTo(Array, Int32)

ICollection.Count

有关此成员的说明,请参见 Count

ICollection.IsSynchronized

有关此成员的说明,请参见 IsSynchronized

ICollection.SyncRoot

有关此成员的说明,请参见 SyncRoot

IEnumerable.GetEnumerator()

有关此成员的说明,请参见 GetEnumerator()

IList.Add(Object)

有关此成员的说明,请参见 Add(Object)

IList.Clear()

有关此成员的说明,请参见 Clear()

IList.Contains(Object)

有关此成员的说明,请参见 Contains(Object)

IList.IndexOf(Object)

有关此成员的说明,请参见 IndexOf(Object)

IList.Insert(Int32, Object)

有关此成员的说明,请参见 Insert(Int32, Object)

IList.IsFixedSize

有关此成员的说明,请参见 IsFixedSize

IList.IsReadOnly

有关此成员的说明,请参见 IsReadOnly

IList.Item[Int32]

有关此成员的说明,请参见 Item[Int32]

IList.Remove(Object)

有关此成员的说明,请参见 Remove(Object)

IList.RemoveAt(Int32)

有关此成员的说明,请参见 RemoveAt(Int32)

扩展方法

Cast<TResult>(IEnumerable)

IEnumerable 的元素强制转换为指定的类型。

OfType<TResult>(IEnumerable)

根据指定类型筛选 IEnumerable 的元素。

AsParallel(IEnumerable)

启用查询的并行化。

AsQueryable(IEnumerable)

IEnumerable 转换为 IQueryable

适用于

另请参阅