示例#1
0
		public Template(TemplateEngine templateEngine, ITemplateGeneratorHost host, TemplateContext templateContext)
		{
			_templateEngine = templateEngine;
			_host = host;
			_templateContext = templateContext;
		}
		internal string _Preview(TemplateInfo templateInfo, ITemplateGeneratorHost host, TemplateEngineSettings settings)
		{
			StartLogging();
			ILog log = LogManager.GetLogger(typeof(TemplateEngineProxy));
			log.Debug(string.Format("Entering AppDomain: {0} {1}", AppDomain.CurrentDomain.FriendlyName, AppDomain.CurrentDomain.BaseDirectory));
			TemplateEngine templateEngine = new TemplateEngine();
			ValidationUtils.ObjectNotNull(templateEngine, "templateEngine");
			return templateEngine.Preview(templateInfo, host, settings);
		}
示例#3
0
 public Template(TemplateEngine templateEngine, ITemplateGeneratorHost host, TemplateContext templateContext)
 {
     _templateEngine  = templateEngine;
     _host            = host;
     _templateContext = templateContext;
 }
		internal void _Execute(TemplateInfo templateInfo, ITemplateGeneratorHost host, TemplateEngineSettings settings)
		{
			StartLogging();
			ILog log = LogManager.GetLogger(typeof(TemplateEngineProxy));
			log.Debug(string.Format("Entering AppDomain: {0} {1}", AppDomain.CurrentDomain.FriendlyName, AppDomain.CurrentDomain.BaseDirectory));
			TemplateEngine templateEngine = new TemplateEngine();
			templateEngine.Execute(templateInfo, host, settings);
		}