System::Xml::Schema::XmlSchemaObjectCollection class

XmlSchemaObjectCollection class

XmlSchemaObjects 的集合。

class XmlSchemaObjectCollection : public System::Collections::CollectionBase<SharedPtr<System::Xml::Schema::XmlSchemaObject>>

方法

方法描述
Add(const SharedPtr<XmlSchemaObject>&)将一个 XmlSchemaObject 添加到 XmlSchemaObjectCollection
Contains(const SharedPtr<XmlSchemaObject>&)指示指定的 XmlSchemaObject 是否在 XmlSchemaObjectCollection 中。
CopyTo(const ArrayPtr<SharedPtr<XmlSchemaObject>>&, int32_t)将集合中的所有 XmlSchemaObjects 复制到给定数组中,从给定索引开始。
GetEnumerator() override返回一个枚举器,用于遍历包含在 XmlSchemaObjectCollection 中的 XmlSchemaObjects。
virtual idx_get(int32_t)返回位于指定索引的 XmlSchemaObject
virtual idx_set(int32_t, SharedPtr<XmlSchemaObject>)在指定索引处设置 XmlSchemaObject
IndexOf(const SharedPtr<XmlSchemaObject>&)返回对应于指定的 XmlSchemaObject 的集合索引。
Insert(int32_t, const SharedPtr<XmlSchemaObject>&)XmlSchemaObject 插入到 XmlSchemaObjectCollection
Remove(const SharedPtr<XmlSchemaObject>&)XmlSchemaObjectCollection 中移除 XmlSchemaObject
SetTemplateWeakPtr(uint32_t) override将第 n 个模板参数设置为弱指针(而不是共享指针)。允许在容器中将指针切换为弱模式。
XmlSchemaObjectCollection()初始化 XmlSchemaObjectCollection 类的新实例。
XmlSchemaObjectCollection(const SharedPtr<XmlSchemaObject>&)初始化 XmlSchemaObjectCollection 类的新实例,该实例接受一个 XmlSchemaObject

Typedefs

类型定义描述
Ptr此类实例的共享指针别名。

备注

此类的对象只能使用 System::MakeObject() 函数分配。切勿在栈上或使用 new 运算符创建此类型的实例,因为这会导致运行时错误和/或断言故障。始终将此类包装到 System::SmartPtr 指针中,并使用该指针将其作为参数传递给函数。

另见