Method | Description | |
---|---|---|
EmitService ( Mono.Cecil.MethodDefinition targetMethod, IDependency dependency, IImplementation implementation, IImplementation>.IDictionary |
Emits a service as a singleton type.
|
Method | Description | |
---|---|---|
EmitSingletonInstantiation ( IDependency dependency, IImplementation implementation, IImplementation>.IDictionary |
Defines the instructions that will instantiate the singleton instance itself.
|
Method | Description | |
---|---|---|
AddDefaultSingletonConstructor ( Mono.Cecil.ModuleDefinition module, string singletonName, TypeAttributes typeAttributes, |
Adds a default constructor to the singleton type.
|
|
DefineGetInstance ( Mono.Cecil.TypeDefinition singletonType, Mono.Cecil.Cil.ILProcessor il, |
Defines the factory method on the singleton type.
|
|
DefineNestedConstructors ( Mono.Cecil.ModuleDefinition module, Mono.Cecil.TypeDefinition nestedType ) : Mono.Cecil.MethodDefinition |
Defines the nested constructors for the singleton type.
|
|
DefineNestedType ( Mono.Cecil.ModuleDefinition module, Mono.Cecil.TypeDefinition singletonType, |
Defines the nested type that will instantiate the actual singleton service instance.
|
|
DefineStaticConstructor ( Mono.Cecil.ModuleDefinition module, Mono.Cecil.TypeDefinition nestedType ) : Mono.Cecil.MethodDefinition |
Defines the static constructor for the nested type.
|
public EmitService ( Mono.Cecil.MethodDefinition targetMethod, IDependency dependency, IImplementation implementation, IImplementation>.IDictionary |
||
targetMethod | Mono.Cecil.MethodDefinition | The |
dependency | IDependency | The dependency that will be instantiated by the container. |
implementation | IImplementation | The implementation that will be used to instantiate the dependency. |
serviceMap | IImplementation>.IDictionary | The service map the contains the current application dependencies. |
return | void |
protected EmitSingletonInstantiation ( IDependency dependency, IImplementation implementation, IImplementation>.IDictionary |
||
dependency | IDependency | The dependency that will be instantiated by the singleton. |
implementation | IImplementation | The implementation that will instantiate the dependency. |
serviceMap | IImplementation>.IDictionary | The service map that contains the list of dependencies in the application. |
instanceField | The field that will hold the singleton instance. | |
cctor | Mono.Cecil.MethodDefinition | The static constructor itself. |
module | Mono.Cecil.ModuleDefinition | The target module. |
targetMethod | Mono.Cecil.MethodDefinition | The target method that will instantiate the service instance. |
return | void |