Class CodeGeneratorUtils
Provides static methods related to dynamic assembly generation.
public static class CodeGeneratorUtils
- Inheritance
-
CodeGeneratorUtils
Methods
- EmitApplicationLog(ILGenerator, string)
Emits Log(object?, LogItemKind) with
value
parameter.
- EmitStringMethod(ILGenerator, MethodInfo, string)
Emits method call with
value
parameter.
- GetDotNetPathFromSystemDllPath()
Gets dotnet path based on the GetSystemDllPath() result.
- GetEventLogDelegate(EventInfo)
Gets event logging delegate.
- GetModuleBuilder()
Gets ModuleBuilder for dynamic assembly generation.
- GetSystemDllPath()
Gets path to folder with System.dll. Returned value is similar to this: 'C:\Program Files\dotnet\shared\Microsoft.NETCore.App\9.0.1'.
- Log(string)
Logs string.
- LogEvent(string, string)
Logs event if it is allowed to log it. Used internally by the event logger.