Esempio n. 1
0
 static void Main(string[] args)
 {
     var connectionString = "mongodb://localhost";
     var client = new MongoClient(connectionString);
     var server = client.GetServer();
     var database = server.GetDatabase("test");
     var collection = database.GetCollection<TodoItem>("todo");
     ITodoListDao todoListDao = new MongoDriverDao(collection);
     readInput(todoListDao);
 }
Esempio n. 2
0
        static void Main(string[] args)
        {
            var          connectionString = "mongodb://localhost";
            var          client           = new MongoClient(connectionString);
            var          server           = client.GetServer();
            var          database         = server.GetDatabase("test");
            var          collection       = database.GetCollection <TodoItem>("todo");
            ITodoListDao todoListDao      = new MongoDriverDao(collection);

            readInput(todoListDao);
        }