Class HierarchicalComponentContainer<TContainer, TComponent>
Base class that stores a set of hierarchical components by type. Other containers can be added as dependencies to get inherited or overridden components.
Inheritance
Implements
Inherited Members
Namespace: Unity.Build
Assembly: solution.dll
Syntax
public abstract class HierarchicalComponentContainer<TContainer, TComponent> : ScriptableObjectPropertyContainer<TContainer>, ISerializationCallbackReceiver where TContainer : HierarchicalComponentContainer<TContainer, TComponent>
Type Parameters
| Name | Description |
|---|---|
| TContainer | Type of the component container. |
| TComponent | Components base type. |
Methods
| Name | Description |
|---|---|
| AddDependency(TContainer) | Add a dependency to this container. Circular dependencies or dependencies on self are not allowed. |
| AsReadOnly() | Returns a read-only wrapper for this container. |
| ClearComponents() | Remove all components from this container. |
| ClearDependencies() | Remove all dependencies from this container. |
| CreateInstance(TContainer) | Create a new instance that duplicates the specified container. |
| GetComponent(Type) | Get the value of a Type component. |
| GetComponentOrDefault(Type) | Get the value of a Type component if found. Otherwise an instance created using TypeConstruction utility. The container is not modified. |
| GetComponentOrDefault<T>() | Get the value of a |
| GetComponentSource(Type, bool) | Get the source container from which the component value is coming from. |
| GetComponentSource<T>(bool) | Get the source container from which the component value is coming from. |
| GetComponentTypes() | Get a flatten list of all component types from this container and its dependencies. |
| GetComponent<T>() | Get the value of a |
| GetComponents() | Get a flatten list of all components recursively from this container and its dependencies. |
| GetComponents(Type) | Get a flatten list of all components recursively from this container and its dependencies, that matches Type. |
| GetComponents<T>() | Get a flatten list of all components recursively from this container and its dependencies, that matches |
| GetDependencies() | Get a flatten list of all dependencies recursively from this container and its dependencies. |
| HasComponent(Type) | Determine if a Type component is stored in this container or its dependencies. |
| HasComponentOnDependency(Type) | |
| HasComponentOnSelf(Type) | |
| HasComponent<T>() | Determine if a |
| HasDependency(TContainer) | Determine if a dependency exist in this container or its dependencies. |
| IsComponentInherited(Type) | Determine if a Type component is inherited from a dependency. |
| IsComponentInherited<T>() | Determine if a |
| IsComponentOverridden(Type) | Determine if a Type component overrides a dependency. |
| IsComponentOverridden<T>() | Determine if a |
| IsComponentOverriding(Type) | Determines if component overrides a dependency. |
| IsComponentOverriding<T>() | Determines if component overrides a dependency. |
| OnComponentConstruct(ref TComponent) | |
| RemoveComponent(Type) | Remove a Type component from this container. |
| RemoveComponent<T>() | Remove all |
| RemoveDependency(TContainer) | Remove a dependency from this container. |
| Reset() | Reset this asset in preparation for deserialization. |
| Sanitize() | Sanitize this asset after deserialization. |
| SetComponent(Type) | Set the value of a Type component on this container using an instance created using TypeConstruction utility. |
| SetComponent(Type, TComponent) | Set the value of a Type component on this container. |
| SetComponent<T>() | Set the value of a |
| SetComponent<T>(T) | Set the value of a |
| TryGetComponent(Type, out TComponent) | Try to get the value of a Type component. |
| TryGetComponent<T>(out T) | Try to get the value of a |