예제 #1
0
 public void Update(Speaker speaker)
 {
     var query = Query<Speaker>.EQ(e => e.Id, speaker.Id);
     var update = Update<Speaker>.Replace(speaker); // update modifiers
     _database.GetCollection<Speaker>("speakers").Update(query, update);
 }
예제 #2
0
 public void Add(Speaker speaker)
 {
     _database.GetCollection<Speaker>("speakers").Save(speaker);
 }