public UpdateDeckCommandHandler(IValidator <DeckInputModel> validator, IDeckService deckService, IMapper mapper, IUserService userService)
 {
     _validator   = validator;
     _deckService = deckService;
     _mapper      = mapper;
     _userService = userService;
 }
Пример #2
0
 public HomeController(IUserService userService, IDeckService deckService, ICardService cardService, ILanguageService languageService)
 {
     _userService     = userService;
     _deckService     = deckService;
     _cardService     = cardService;
     _languageService = languageService;
 }
Пример #3
0
 public GamePipelineService(IGameService gameService, IDeckService deckService,
                            ICardService cardService)
 {
     _gameService = gameService;
     _deckService = deckService;
     _cardService = cardService;
 }
Пример #4
0
 public GameController(IGameService gameService, IDeckService deckService,
                       IGamePipelineService gamePipelineService, IMapper mapper)
 {
     _gameService         = gameService;
     _deckService         = deckService;
     _gamePipelineService = gamePipelineService;
     _mapper = mapper;
 }
Пример #5
0
 public PokerHands(IHandPrinterService handPrinterService,
                   IDeckService deckService,
                   IHandRankerService handRankerService)
 {
     _handPrinterService = handPrinterService;
     _deckService        = deckService;
     _handRankerService  = handRankerService;
 }
Пример #6
0
        public Game(PresentationModel presentationModel)
        {
            _presentationModel = presentationModel;

            _deck   = new DeckService();
            _user   = new UserService(_deck.DrawCard, _presentationModel.showPlayer, _presentationModel.showRoundResult, _presentationModel.getUserAction);
            _bots   = new BotService(_deck.DrawCard, _presentationModel.showPlayer, _presentationModel.showRoundResult);
            _dealer = new DealerService(_deck.DrawCard, _presentationModel.showPlayer);
        }
Пример #7
0
        public DecksViewModel(IDeckService deckService, INavigationService navigationService, IDialogService dialogService)
        {
            _deckService       = deckService;
            _navigationService = navigationService;
            _dialogService     = dialogService;

            _decks.CollectionChanged += DecksChanged;

            MessagingCenter.Subscribe <Deck>(this, App.MESSAGES.NEW_DECK_SAVED, (d) => RefreshDecksCommand.Execute(null));
        }
 public UploadYgoProDeckCommandHandler
 (
     IValidator <UploadYgoProDeckCommand> commandValidator,
     IValidator <YgoProDeck> ygoProDeckValidator,
     IDeckService deckService
 )
 {
     _commandValidator    = commandValidator;
     _ygoProDeckValidator = ygoProDeckValidator;
     _deckService         = deckService;
 }
Пример #9
0
        public void SetUp()
        {
            _deckService = Substitute.For <IDeckService>();
            var config = new MapperConfiguration
                         (
                cfg => { cfg.AddProfile(new CardProfile()); }
                         );

            var mapper = config.CreateMapper();


            _sut = new DeckByIdQueryHandler(_deckService, mapper);
        }
 public GameController(
     IGameService gameService,
     IDeckService deckService,
     ICardService cardService,
     IDealerService dealerService,
     IPlayerService playerService)
 {
     _gameService   = gameService;
     _deckService   = deckService;
     _cardService   = cardService;
     _dealerService = dealerService;
     _playerService = playerService;
 }
 public UpdateDeckThumbnailCommandHandler
 (
     IOptions <ApplicationSettings> settings,
     IValidator <DeckThumbnailInputModel> validator,
     IUserService userService,
     IDeckService deckService,
     IMapper mapper
 )
 {
     _settings    = settings;
     _validator   = validator;
     _userService = userService;
     _deckService = deckService;
     _mapper      = mapper;
 }
        public DeckListViewModel(ITrackerFactory factory)
        {
            this.messanger = factory.GetService <IMessenger>();
            messanger.Register <DeckListFilterChanged>(this, DeckFilterChanged, ControlMessangerContext.DeckList_DeckFilterControl);
            messanger.Register <EditDeck>(this, EditDeckFinished, Utils.Messages.EditDeck.Context.EditFinished);
            messanger.Register <EditDeck>(this, CommandHideDeckExecute, Utils.Messages.EditDeck.Context.Hide);
            messanger.Register <EditDeck>(this, CommandUnHideDeckExecute, Utils.Messages.EditDeck.Context.UnHide);
            messanger.Register <EditDeck>(this, CommandDeleteDeckExecute, Utils.Messages.EditDeck.Context.Delete);

            this.trackerFactory = factory;
            this.tracker        = factory.GetTracker();
            FilteredDecks       = new ObservableCollection <Deck>(tracker.Decks);

            deckService = trackerFactory.GetService <IDeckService>();
            settings    = trackerFactory.GetService <ISettings>();
        }
        public CardsViewModel(INavigationService navigationService, ICardsService cardsService, IDialogService dialog, IDeckService deckService)
        {
            _navigationService = navigationService;
            _cardsService      = cardsService;
            _dialog            = dialog;
            _deckService       = deckService;

            _cardsService.DataUpdated += (o, e) =>
            {
                Device.BeginInvokeOnMainThread(async() =>
                {
                    await InitializeAsync(CurrentDeck);
                    await ApplyFilters();
                });
            };
        }
Пример #14
0
        internal MainWindowViewModel(TrackerFactory trackerFactory)
        {
            this.trackerFactory = trackerFactory;
            tracker             = trackerFactory.GetTracker();
            messanger           = trackerFactory.GetMessanger();
            messanger.Register <Utils.Messages.EditDeck>(this, EditDeckStart, Utils.Messages.EditDeck.Context.StartEdit);
            messanger.Register <Utils.Messages.EditDeck>(this, EditDeckFinished, Utils.Messages.EditDeck.Context.EditFinished);
            messanger.Register <Utils.Messages.EditGame>(this, EditGameStart, Utils.Messages.EditGame.Context.StartEdit);
            messanger.Register <Utils.Messages.EditGame>(this, EditGameFinished, Utils.Messages.EditGame.Context.EditFinished);
            messanger.Register <Utils.Messages.EditSettings>(this, EditSettingsFinished, Utils.Messages.EditSettings.Context.EditFinished);

            deckService = trackerFactory.GetService <IDeckService>();
            settings    = trackerFactory.GetService <ISettings>();

            this.OverlayWindows.Add(new OverlayToolbar());
            this.OverlayWindows.Add(new DeckOverlay());
            this.OverlayWindows.CollectionChanged += (s, e) => RaisePropertyChangedEvent(nameof(OverlayWindows));
        }
Пример #15
0
    //public GetCountCardsByValue(CardValue value)
    //{
    //    ca
    //}

    public Deck(int playerCount)
    {
        deckService = new DeckService();
        for (int i = 0; i < playerCount; i++)
        {
            cards.Add(new Card()
            {
                Value = CardValue.Stone
            });
            cards.Add(new Card()
            {
                Value = CardValue.Scissors
            });
            cards.Add(new Card()
            {
                Value = CardValue.Paper
            });
        }
        cards = deckService.mixCards(cards);
    }
 public static void ClassInit(TestContext context)
 {
     _deckService = new DeckServiceStub();
     _gameService = new GameService(_deckService);
 }
Пример #17
0
 public DeckSearchQueryHandler(IDeckService deckService)
 {
     _deckService = deckService;
 }
Пример #18
0
 public GameController(IGameService gameService, IDeckService deckService)
 {
     _gameService = gameService;
     _deckService = deckService;
 }
Пример #19
0
 public Services(IShuffleService shuffleService, IDeckService <IDeck> deckService)
 {
     ShuffleService = shuffleService;
     DeckService    = deckService;
 }
Пример #20
0
 public DeckController(ILogger <DeckController> logger, IDeckService service)
 {
     _logger  = logger;
     _service = service;
 }
Пример #21
0
 /// <summary>
 /// Initializes a new instance of the <see cref="DecksController"/> class.
 /// </summary>
 /// <param name="gameControlService">The game control service.</param>
 /// <exception cref="System.ArgumentNullException">gameControlService</exception>
 public DecksController(IDeckService gameControlService)
 {
     _gameControlService = gameControlService
                           ?? throw new ArgumentNullException(nameof(gameControlService));
 }
Пример #22
0
 /// <summary>
 /// Constructor to allow for mocks to be put in place for testing.
 /// </summary>
 /// <param name="deckService">The mock deck service to use during this test.</param>
 public GameService(IDeckService deckService)
 {
     _deckService = deckService;
 }
        public void SetUp()
        {
            _deckService = Substitute.For <IDeckService>();

            _sut = new DecksByUsernameQueryHandler(_deckService);
        }
 public DecksByUserIdQueryHandler(IDeckService deckService)
 {
     _deckService = deckService;
 }
Пример #25
0
 public DownloadDeckSWDestinyDBExtractor(IDeckService deckService)
 {
     _deckService = deckService;
 }
Пример #26
0
 public HomeController()
 {
     _deckService = new DeckService();
 }
Пример #27
0
 public DecksController(IDeckService deckService)
 {
     _deckService = deckService;
 }
Пример #28
0
 public DeckByIdQueryHandler(IDeckService deckService, IMapper mapper)
 {
     _deckService = deckService;
     _mapper      = mapper;
 }
Пример #29
0
 public AnalyticsService(ApplicationDbContext db, IDeckService deckService, IAccessService accessService)
 {
     Database       = db;
     _deckService   = deckService;
     _accessService = accessService;
 }
Пример #30
0
 public DeckController(IDeckService deckService, IMapper mapper, ILogger <DeckController> logger) : base(logger)
 {
     _deckService = deckService;
     _mapper      = mapper;
 }
 public AnalyticsController(IAnalyticsService analyticsService, IDeckService deckService) // Получение страницы аналитики обучения пользователя
 {
     _analyticsService = analyticsService;
     _deckService      = deckService;
 }