コード例 #1
0
 // cut out from here , List<IReservation> reservationList
 // The constructor is private as its a singleton and I only allow one instance which is created with the GetInstance() method
 private Model(IDataLayer
         _DataLayer)
 {
     userList = new List<IUser>();
             dataLayer = _DataLayer;
         userList = dataLayer.getAllUsers(); // setup Models userList so we can login
     _reservationList = dataLayer.GetAllReservations();//  ReservationList;    // CHANGED to Capital R
             _roomTypeList = dataLayer.getAllRoomTypes();
             _roomList = dataLayer.getAllRooms();
             _supplierList = dataLayer.getAllSuppliers();
         _stockRoomList = dataLayer.getAllStockRooms();
     _stockRoomItemsList = dataLayer.getAllStockRoomItems();
         _productList = dataLayer.getAllProducts();
     _guestList = dataLayer.getAllGuests();
     _restaurantItemsList = dataLayer.getAllRestaurantItems();
     _stockItemsList = dataLayer.GetAllStockItems();
     _faultList = dataLayer.getAllFaults();
     _stockOrderList = dataLayer.getAllStockOrders();
     _stockOrderItemsList = dataLayer.getAllStockOrderItems();
         _creditCards = dataLayer.GetAllCreditCards();
     _laundryList = dataLayer.getAllLaundry();
         _additionalGuestList = dataLayer.getAllAdditionalGuests();
 }