Beispiel #1
0
        public DataService(ITalktelecomDbDatabaseSettings settings)
        {
            var client = new MongoClient(settings.ConnectionString);

            var database = client.GetDatabase(settings.DatabaseName);

            _datas = database.GetCollection <Data>(settings.DataCollectionName);
        }
Beispiel #2
0
        public BookService(ITalktelecomDbDatabaseSettings settings)
        {
            var client = new MongoClient(settings.ConnectionString);

            var database = client.GetDatabase(settings.DatabaseName);

            _books = database.GetCollection <Book>(settings.BooksCollectionName);
        }