protected string ProcessView(string templatePath) { var sw = new StringWriter(); ControllerContext.LayoutNames = Layouts; EngineContext.CurrentControllerContext = ControllerContext; VelocityViewEngine.Process(templatePath, sw, EngineContext, Controller, ControllerContext); lastOutput = sw.ToString(); return(lastOutput); }
///<summary> /// Processes the view - using the templateName to obtain the correct template /// and writes the results to the System.TextWriter No layout is applied! /// </summary> public override void Process(TextWriter output, IRailsEngineContext context, Controller controller, String viewName) { _nvelocityViewEngine.Process(output, context, controller, viewName); }