public PaymentService(IImmovableStoreDatabaseSettings settings) { var client = new MongoClient(settings.ConnectionString); var database = client.GetDatabase(settings.DatabaseName); settings.ImmovableCollectionName = "PaymentCollection"; _payments = database.GetCollection <Payment>(settings.ImmovableCollectionName); }
public CustomerService(IImmovableStoreDatabaseSettings settings) { var client = new MongoClient(settings.ConnectionString); var database = client.GetDatabase(settings.DatabaseName); settings.ImmovableCollectionName = "CustomerCollection"; _customers = database.GetCollection <Customer>(settings.ImmovableCollectionName); }
public PropertyService(IImmovableStoreDatabaseSettings settings) { var client = new MongoClient(settings.ConnectionString); var database = client.GetDatabase(settings.DatabaseName); settings.ImmovableCollectionName = "PropertyCollection"; _properties = database.GetCollection <Property>(settings.ImmovableCollectionName); }
public MonthService(IImmovableStoreDatabaseSettings settings) { var client = new MongoClient(settings.ConnectionString); var database = client.GetDatabase(settings.DatabaseName); settings.ImmovableCollectionName = "MonthCollection"; _months = database.GetCollection <Month>(settings.ImmovableCollectionName); }
public LessorService(IImmovableStoreDatabaseSettings settings) { var client = new MongoClient(settings.ConnectionString); var database = client.GetDatabase(settings.DatabaseName); settings.ImmovableCollectionName = "LessorCollection"; _lessors = database.GetCollection <Lessor>(settings.ImmovableCollectionName); }