Beispiel #1
0
        public GameDataPersister(IGameDataStoreDataAccessService gameDataStoreDataAccessService
                                 , IMapperFactory mapperFactory)
        {
            _gameDataStoreDataAccessService = gameDataStoreDataAccessService;

            _mapperFactory            = mapperFactory;
            _gameDataPersistMapper    = _mapperFactory.Build <IGame, StoredGameData>("StoreGameDataMapper");
            _fundsDriverPersistMapper = _mapperFactory.Build <Item, StoredItem>();
        }
        public GameDataChangesNotifier(
            IGameDataStoreDataAccessService gameDataStoreDataAccessService
            , IMapperFactory mapperFactory
            , INotifyConsumerClientFactory notifyConsumerService)
        {
            _mapperFactory            = mapperFactory;
            _gameDataRefreshMapper    = _mapperFactory.Build <IGame, GameData>("GameDataMapper");
            _fundsDriverRefreshMapper = _mapperFactory.Build <Item, Common.Contract.Items.Item>();

            _notifyConsumerService = notifyConsumerService;
        }
        public NotifyGameDataChanged(string userId
                                     , string userName
                                     , IGameDataStoreDataAccessService gameDataStoreDataAccessService
                                     , IMapperFactory mapperFactory
                                     , INotifyConsumerClientFactory notifyConsumerService)
        {
            _userId   = userId;
            _userName = userName;
            _gameDataStoreDataAccessService = gameDataStoreDataAccessService;

            _mapperFactory = mapperFactory;

            _gameDataPersistMapper    = _mapperFactory.Build <IGame, StoredGameData>("StoreGameDataMapper");
            _gameDataRefreshMapper    = _mapperFactory.Build <IGame, GameData>("GameDataMapper");
            _fundsDriverPersistMapper = _mapperFactory.Build <Item, StoredItem>();
            _fundsDriverRefreshMapper = _mapperFactory.Build <Item, Common.Contract.Items.Item>();
            _notifyConsumerService    = notifyConsumerService;
        }