Exemplo n.º 1
0
 public void registerPerson(Person man)
 {
     var people = _db.GetCollection<Person>("people");
     people.Insert(man);
 }
Exemplo n.º 2
0
 protected void walk(String path)
 {
     var directories = Directory.GetDirectories(path);
     for (int num = 0; num < 2; num++)
     {
         var totalSpan = Overseer.observe("Training");
         var problem = readProblem(num, directories);
         var man = new Person
         {
             model = train(problem),
             name = "man " + num
         };
         var span = Overseer.observe("Training.DB-Write");
         Mongoid.getInstance().registerPerson(man);
         span.die();
         totalSpan.die();
     }
     Overseer.log();
 }