예제 #1
0
 public void InsertSprint(Sprint sprint)
 {
     if ((sprint.EntityState != EntityState.Detached))
     {
         this.ObjectContext.ObjectStateManager.ChangeObjectState(sprint, EntityState.Added);
     }
     else
     {
         this.ObjectContext.Sprints.AddObject(sprint);
     }
 }
예제 #2
0
 public void DeleteSprint(Sprint sprint)
 {
     if ((sprint.EntityState != EntityState.Detached))
     {
         this.ObjectContext.ObjectStateManager.ChangeObjectState(sprint, EntityState.Deleted);
     }
     else
     {
         this.ObjectContext.Sprints.Attach(sprint);
         this.ObjectContext.Sprints.DeleteObject(sprint);
     }
 }
예제 #3
0
 public void UpdateSprint(Sprint currentSprint)
 {
     this.ObjectContext.Sprints.AttachAsModified(currentSprint, this.ChangeSet.GetOriginal(currentSprint));
 }
예제 #4
0
 /// <summary>
 /// Create a new Sprint object.
 /// </summary>
 /// <param name="sprintId">Initial value of the SprintId property.</param>
 public static Sprint CreateSprint(global::System.Int32 sprintId)
 {
     Sprint sprint = new Sprint();
     sprint.SprintId = sprintId;
     return sprint;
 }
예제 #5
0
 /// <summary>
 /// Deprecated Method for adding a new object to the Sprints EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToSprints(Sprint sprint)
 {
     base.AddObject("Sprints", sprint);
 }
예제 #6
0
 /// <summary>
 /// Deprecated Method for adding a new object to the Sprints EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToSprints(Sprint sprint)
 {
     base.AddObject("Sprints", sprint);
 }