Class PropertyBag
Static registration for property bags.
Namespace: Unity.Properties
Syntax
public static class PropertyBag
Methods
Register<TContainer>(ContainerPropertyBag<TContainer>)
Registers a strongly typed ContainerPropertyBag<TContainer> for a type.
Declaration
public static void Register<TContainer>(ContainerPropertyBag<TContainer> propertyBag)
Parameters
| Type | Name | Description |
|---|---|---|
| ContainerPropertyBag<TContainer> | propertyBag | The ContainerPropertyBag<TContainer> to register. |
Type Parameters
| Name | Description |
|---|---|
| TContainer | The container type this property bag describes. |
RegisterDictionary<TContainer, TDictionary, TKey, TValue>()
Registers an internal dictionary property bag for the given types.
Declaration
public static void RegisterDictionary<TContainer, TDictionary, TKey, TValue>()
where TDictionary : IDictionary<TKey, TValue>
Type Parameters
| Name | Description |
|---|---|
| TContainer | The container type to register. |
| TDictionary | The generic dictionary type to register. |
| TKey | The key type to register. |
| TValue | The value type to register. |
RegisterList<TContainer, TList, TElement>()
Registers an internal list property bag for the given types.
Declaration
public static void RegisterList<TContainer, TList, TElement>()
where TList : IList<TElement>
Type Parameters
| Name | Description |
|---|---|
| TContainer | The container type to register. |
| TList | The generic list type to register. |
| TElement | The element type to register. |
RegisterSet<TContainer, TSet, TElement>()
Registers an internal list property bag for the given types.
Declaration
public static void RegisterSet<TContainer, TSet, TElement>()
where TSet : ISet<TElement>
Type Parameters
| Name | Description |
|---|---|
| TContainer | The container type to register. |
| TSet | The generic set type to register. |
| TElement | The element type to register. |