System::Collections::Generic::HashSet 类
HashSet class
前向声明 HashSet 类。
template<typename T>class HashSet : public System::Collections::Generic::BaseSet<T, std::unordered_set<T, EqualityComparerHashAdapter<T>, EqualityComparerAdapter<T>, System::Details::CollectionHelpers::ContainerPointerMode<T>::allocator_type>>
方法
| 方法 | 描述 |
|---|---|
| HashSet() | RTTI 信息。 |
| HashSet(int) | 创建具有指定容量的空集合。 |
| HashSet(const SharedPtr<IEqualityComparer<T>>&) | 创建使用指定相等比较器的空集合。 |
| HashSet(const SharedPtr<IEnumerable<T>>&) | 基于可枚举值创建 hashset。 |
Typedefs
| 类型定义 | 描述 |
|---|---|
| BaseType | 基类型。 |
| ThisPtr | 指针类型。 |
| ThisType | 自身类型。 |
备注
基于哈希的集合实现。此类的对象只能使用 System::MakeObject() 函数进行分配。切勿在栈上或使用 operator new 创建此类型的实例,因为这会导致运行时错误和/或断言故障。始终将此类包装到 System::SmartPtr 指针中,并使用该指针将其作为参数传递给函数。
另见
- Class BaseSet
- Namespace System::Collections::Generic
- Library Aspose.Font for C++