public OperationResult UpdateItem(T entity) { OperationResult opResult = OperationResult.GetInstance(); try { if (entity == null) { throw new ArgumentNullException("object should not be null"); } ChangeSet changes = _dataContextFactory.Context.GetChangeSet(); _dataContextFactory.SaveAll(); changes = null; } catch (Exception ex) { opResult.IsFailed = true; opResult.ErrorMessage = ex.Message + ex.StackTrace; } return(opResult); }
/// <summary>See IRepository.</summary> public void SaveAll() { _dataContextFactory.SaveAll(); }