Esempio n. 1
0
 protected FacadeException HandleException(string category, string source, string errMsg, Exception innerException)
 {
     FacadeException ex = new FacadeException(errMsg, innerException);
     if (LogWriter != null)
     {
         LogWriter.Write(category, source, ex);
     }
     return ex;
 }
Esempio n. 2
0
 protected FacadeException HandleException(string category, string errMsg, Exception innerException, params object[] objs)
 {
     StringBuilder sb = new StringBuilder();
     sb.AppendLine(errMsg);
     if (objs != null && objs.Length > 0)
     {
         foreach (object obj in objs)
         {
             sb.AppendLine(ORMHelper.GetEntityInfoMessage(objs[0]));
             sb.AppendLine();
         }
     }
     FacadeException ex = new FacadeException(sb.ToString(), innerException);
     if (LogWriter != null)
     {
         LogWriter.Write(category, errMsg, ex);
     }
     return ex;
 }