public override IResult Execute(HttpContextBase context) { var q = context.Request.QueryString["q"]; var p = int.Parse(context.Request.QueryString["p"]); new HQLCodeAssist(new NHConfigDataProvider(NHWebConsoleSetup.Configuration())).CodeComplete(q, p, this); return(new ViewResult(new SuggestionResponse { Error = error, Suggestions = string.Join(",", suggestions.Select(s => string.Format("\"{0}\"", s)).ToArray()), }, ViewName)); }
public override void ProcessRequest(HttpContext context) { Session = NHWebConsoleSetup.OpenSession(); try { Session.FlushMode = FlushMode.Never; base.ProcessRequest(context); } finally { if (NHWebConsoleSetup.DisposeSession) { Session.Dispose(); } } }
public IndexController() { Cfg = NHWebConsoleSetup.Configuration(); }