예제 #1
0
 partial void UpdatePulse(Pulse instance);
예제 #2
0
 partial void DeletePulse(Pulse instance);
예제 #3
0
 partial void InsertPulse(Pulse instance);
예제 #4
0
		private void detach_Pulses(Pulse entity)
		{
			this.SendPropertyChanging();
			entity.Client = null;
		}
예제 #5
0
		private void attach_Pulses(Pulse entity)
		{
			this.SendPropertyChanging();
			entity.Client = this;
		}
예제 #6
0
        public void SavePulse(Pulse pulse)
        {
            // if its a new Pulse, insert it
            if (pulse.PulseID == 0)
            {
                _db.Pulses.InsertOnSubmit(pulse);
            }
            else if (_db.Pulses.GetOriginalEntityState(pulse) == null)
            {
                // we are updating an existing Pulse, but it's not attached
                // to the data context, so attach it and detect changes

                _db.Pulses.Attach(pulse);
                _db.Pulses.Context.Refresh(RefreshMode.KeepCurrentValues, pulse);
            }

            _db.SubmitChanges();
        }
예제 #7
0
 public void DeletePulse(Pulse pulse)
 {
     _db.Pulses.DeleteOnSubmit(pulse);
     _db.Pulses.Context.SubmitChanges();
 }