Interface IFactory<TCreate>
Interface to implement Abstract Factory pattern.
Implementers are encouraged to extend the abstract Factory<TObject> class instead of creating their own.
Namespace: BionicCode.Utilities.Net
Assembly: BionicCode.Utilities.Net.Common.dll
Syntax
public interface IFactory<out TCreate>
Type Parameters
| Name | Description |
|---|---|
| TCreate | The type of the instantiated object. |
Properties
| Improve this Doc View SourceFactoryMode
Configures the lifetime scope of the created object instances. Default is Singleton
Declaration
FactoryMode FactoryMode { get; set; }
Property Value
| Type | Description |
|---|---|
| FactoryMode | The lifetime scope Singleton of the created object instances |
Methods
| Improve this Doc View SourceCreate()
Creates the instance.
Declaration
TCreate Create()
Returns
| Type | Description |
|---|---|
| TCreate | An instance of |
Create(Object[])
Creates the instance, allowing arguments.
Declaration
TCreate Create(params object[] args)
Parameters
| Type | Name | Description |
|---|---|---|
| Object[] | args | The arguments for the factory to use to instantiate the type. |
Returns
| Type | Description |
|---|---|
| TCreate | An instance of |