コード例 #1
0
        private LogConfig GetLogConfig(_Assembly assembly)
        {
            var context = Container.Resolve <IPluginExecutionContext>();

            if (!LogConfig.TryParse(context.SharedVariables, out var logConfig))
            {
                logConfig =
                    GetLogConfigFromAssemblyAttribute(assembly) ??
                    new LogConfig(PluginLogOption.Off, null);

                logConfig.Save(context.SharedVariables);
            }

            return(logConfig);
        }