public bool Delete(Speaker t) { var speaker = SpeakerInMemory.GetInstance().Speakers.FirstOrDefault(s => s.Id == t.Id); if (speaker == null) { return(false); } speaker.Deleted = true; return(true); }
public Speaker Update(Speaker t) { var speaker = SpeakerInMemory.GetInstance().Speakers.FirstOrDefault(s => s.Id == t.Id); if (speaker == null) { return(null); } speaker.Birthday = t.Birthday; speaker.Deleted = t.Deleted; speaker.Name = t.Name; speaker.Sessions = t.Sessions; return(speaker); }
public Speaker Create(Speaker t) { t.Id = new Guid(); SpeakerInMemory.GetInstance().Speakers.Append(t); return(t); }
public ICollection <Speaker> FindAllSpeakers() { return((ICollection <Speaker>)SpeakerInMemory.GetInstance().Speakers); }