AggregateServiceGeneratorCreateInstanceTAggregateServiceInterface Method (IComponentContext) |
Generate an aggregate service instance that will resolve its types from context.
Namespace:
Autofac.Extras.AggregateService
Assembly:
Autofac.Extras.AggregateService (in Autofac.Extras.AggregateService.dll) Version: 6.0.0+9a0ae3a0a675c94a74f543addfa4c99a731e7032
Syntax public static Object CreateInstance<TAggregateServiceInterface>(
IComponentContext context
)
Public Shared Function CreateInstance(Of TAggregateServiceInterface) (
context As IComponentContext
) As Object
Parameters
- context
- Type: AutofacIComponentContext
The component context from where types will be resolved.
Type Parameters
- TAggregateServiceInterface
- The interface type for the aggregate service.
Return Value
Type:
ObjectThe aggregate service instance.
Exceptions Exception | Condition |
---|
ArgumentException | Thrown if TAggregateServiceInterface is not an interface. |
See Also