예제 #1
0
 public void Info(object sender, string message, params object[] parameters)
 {
     try
     {
         db.Create(new InfoEntry(sender, message, parameters));
     }
     catch (Exception ex)
     {
         ex.TryToStore(db, this);
     }
 }
예제 #2
0
 public static bool TryToStore(this Exception ex, ICrudProvider storage, object source)
 {
     try
     {
         return(storage != null && storage.Create(new ExceptionEntry(source, ex)) == 1);
     }
     catch
     {
         return(false);
     }
 }
예제 #3
0
 public static bool TryToStore(this Exception ex, ICrudProvider storage, object source)
 {
     try
     {
         return (storage != null && storage.Create(new ExceptionEntry(source, ex)) == 1);
     }
     catch
     {
         return false;
     }
 }