Struct CoreRegistration
Handle to a registered IInitializablePackage. Provides a fluent interface to define its components dependencies and provisions.
Inherited Members
Namespace: Unity.Services.Core.Internal
Assembly: Unity.Services.Core.Internal.dll
Syntax
public readonly struct CoreRegistration
Methods
DependsOn<T>()
Declare the given component type a dependency of the handled package.
Declaration
public CoreRegistration DependsOn<T>() where T : IServiceComponent
Returns
Type | Description |
---|---|
CoreRegistration | Return this registration. |
Type Parameters
Name | Description |
---|---|
T | The type of IServiceComponent to declare as a dependency for the handled package. |
OptionallyDependsOn<T>()
Declare the given component type an optional dependency of the handled package.
Declaration
public CoreRegistration OptionallyDependsOn<T>() where T : IServiceComponent
Returns
Type | Description |
---|---|
CoreRegistration | Return this registration. |
Type Parameters
Name | Description |
---|---|
T | The type of IServiceComponent to declare as an optional dependency for the handled package. |
ProvidesComponent<T>()
Declare the given component type a provided component by the handled package.
Declaration
public CoreRegistration ProvidesComponent<T>() where T : IServiceComponent
Returns
Type | Description |
---|---|
CoreRegistration | Return this registration. |
Type Parameters
Name | Description |
---|---|
T | The type of IServiceComponent to declare provided by the handled package. |