コード例 #1
0
 public ShoppingListRepository(IMongoCollection <ShoppingListDocument> shoppingListCollection, IShoppingItemsRepository <ShoppingListDocument, ShoppingItemDocument> itemsRepository)
 {
     this.shoppingListCollection = shoppingListCollection ?? throw new ArgumentNullException(nameof(shoppingListCollection));
     this.itemsRepository        = itemsRepository ?? throw new ArgumentNullException(nameof(itemsRepository));
 }
コード例 #2
0
 public ShoppingTemplateRepository(IMongoCollection <ShoppingTemplateDocument> templatesCollection, IShoppingItemsRepository <ShoppingTemplateDocument, ShoppingItemDocument> itemsRepository)
 {
     this.templatesCollection = templatesCollection ?? throw new ArgumentNullException(nameof(templatesCollection));
     this.itemsRepository     = itemsRepository ?? throw new ArgumentNullException(nameof(itemsRepository));
 }