# RegisterHashSet

> Creates and registers a IPropertyBag<TContainer> for a HashSet_1 type.

## Definition

* **Type:** Method
* **Namespace:** [Unity.Properties](/engine/6000.5/script-reference/unity/properties.md)
* **Assembly:** UnityEngine.PropertiesModule

## RegisterHashSet\<T>()

Creates and registers a [IPropertyBag\<TContainer>](/engine/6000.5/script-reference/unity/properties/ipropertybag1.md) for a HashSet\_1 type.

```csharp
public static void RegisterHashSet<TElement>()
```

### Remarks

To generate AOT paths for visitors use [PropertyBag.RegisterHashSet](/engine/6000.5/script-reference/unity/properties/propertybag/registerhashset.md) instead.

## RegisterHashSet\<T, U>()

Creates and registers a [IPropertyBag\<TContainer>](/engine/6000.5/script-reference/unity/properties/ipropertybag1.md) for a HashSet\_1 type.

```csharp
public static void RegisterHashSet<TContainer, TElement>()
```

### Remarks

The container is required to provide AOT code paths for [PropertyVisitor](/engine/6000.5/script-reference/unity/properties/propertyvisitor.md).
