protected override void InitDslFactory(ILog logger, DslConfigurationSection configSection) { VariablesDslEngine variablesDslEngine = new VariablesDslEngine(); variablesDslEngine.Storage = new BooFileSystemDslEngineStorage { FileNameFormat = "*.var" }; this.dslFactory.Register<GlobalVariables>(variablesDslEngine); logger.Trace(x => x("VariablesDslEngine for *.var files successully registered")); this.dslFactory.Register<Service>(new ServiceDslEngine()); logger.Trace(x => x("ServiceDslEngine for *.boo files successully registered")); HostDslEngine hostDslEngine = new HostDslEngine(); hostDslEngine.Storage = new BooFileSystemDslEngineStorage { FileNameFormat = "*.host" }; this.dslFactory.Register<Host>(hostDslEngine); logger.Trace(x => x("HostDslEngine for *.host files successully registered")); }
protected override void InitDslFactory(Common.Logging.ILog logger, DslConfigurationSection configSection) { VariablesDslEngine variablesDslEngine = new VariablesDslEngine(); variablesDslEngine.Storage = new CSharpFileSystemDslEngineStorage("*.var", variablesDslEngine.ImplicitBaseClass, assemblyResolver); dslFactory.Register<GlobalVariables>(variablesDslEngine); logger.Trace(x => x("VariablesDslEngine for *.var files successully registered")); var serviceDslEngine = new DslConfig.CSharp.DslEngines.ServiceDslEngine(); serviceDslEngine.Storage = new CSharpFileSystemDslEngineStorage("*.boo", serviceDslEngine.ImplicitBaseClass, assemblyResolver); dslFactory.Register<Service>(serviceDslEngine); logger.Trace(x => x("ServiceDslEngine for *.boo files successully registered")); var hostDslEngine = new DslConfig.CSharp.DslEngines.HostDslEngine(); hostDslEngine.Storage = new CSharpFileSystemDslEngineStorage("*.host", hostDslEngine.ImplicitBaseClass, assemblyResolver); dslFactory.Register<Host>(hostDslEngine); logger.Trace(x => x("HostDslEngine for *.host files successully registered")); }
/// <summary> /// Initializes a new instance of the <see cref="Configuration"/> class. /// This is the main configuration calls /// </summary> /// <param name="configSection">The config section.</param> /// <param name="startUpErrorHandler">The start up error handler.</param> /// <param name="entryAssembly">The entry assembly</param> protected Configuration(DslConfigurationSection configSection, EventHandler<CompilationErrorEventArgs> startUpErrorHandler, Assembly entryAssembly) : base(configSection, startUpErrorHandler, entryAssembly) { this.logger = LogManager.GetLogger<Configuration>(); }