public Tag Add(Tag entity) { if (entity.Id > 0) return entity; context.Tag.AddObject(entity); try { context.SaveChanges(); } catch (OptimisticConcurrencyException e) { //An optimistic concurrency violation has occurred in the data source. throw new ConcurrencyException(e.Message); } return entity; }
public Tag Update(Tag entity) { return entity; }
public void Delete(Tag entity) { context.DeleteObject(entity); }