Inheritance: NHibernate.HibernateException, ISerializable
コード例 #1
0
ファイル: ErrorHandler.cs プロジェクト: alexjamesbrown/n2cms
		private void RedirectToFix(WrongClassException wex)
		{
			if (context.HttpContext != null)
			{
				string url = Url.Parse(beginUrl).ResolveTokens()
					.AppendQuery("action", "fixClass")
					.AppendQuery("id", wex.Identifier);
				logger.Warn("Redirecting to '" + url + "' to fix exception: " + wex);
				context.HttpContext.ClearError();
				context.HttpContext.Response.Redirect(url);
			}
		}
コード例 #2
0
 private void RedirectToFix(WrongClassException wex)
 {
     string url = Url.Parse(editConfig.Installer.FixClassUrl).ResolveTokens().AppendQuery("id", wex.Identifier);
     Trace.WriteLine("Redirecting to '" + url + "' to fix exception: " + wex);
     context.ClearError();
     context.Response.Redirect(url);
 }
 //TODO investigate WrongClassException.Type as equivalent to ex.PersistentClass
 /// <summary>
 /// Initializes a new instance of the <see cref="HibernateObjectRetrievalFailureException"/> class.
 /// </summary>
 /// <param name="ex">The ex.</param>
 public HibernateObjectRetrievalFailureException(WrongClassException ex)
     : base(ex.Type, ex.Identifier, ex.Message, ex)
 {
 }
コード例 #4
0
ファイル: ErrorHandler.cs プロジェクト: spmason/n2cms
 private void RedirectToFix(WrongClassException wex)
 {
     string url = Url.Parse(editConfig.Installer.FixClassUrl).ResolveTokens().AppendQuery("id", wex.Identifier);
     context.ClearError();
     context.Response.Redirect(url);
 }