public virtual LoggingConfiguration Build(ILoggingOptions settings) { BeforeBuildAction?.Invoke(this, settings); var loggingConfiguration = new LoggingConfiguration(settings, ConfigurationBuilder.Build()); AfterBuildAction?.Invoke(loggingConfiguration); return(loggingConfiguration); }
public override LoggingConfiguration Build(ILoggingOptions settings) { BeforeBuildAction?.Invoke(this, settings); var loggingConfiguration = new LoggingConfiguration(settings, _root); AfterBuildAction?.Invoke(loggingConfiguration); return(loggingConfiguration); }
public IServiceProvider Build() { if (_hasBuild) { throw new InvalidOperationException("Only can be built once."); } BeforeBuildAction?.Invoke(_services); var resolver = _services.ToServiceContainer().Build(); AfterBuildAction?.Invoke(resolver); _hasBuild = true; return(resolver); }