public PlayCardCommandHandler(IMediator mediator, IPokerTimeDbContextFactory dbContextFactory, ICurrentParticipantService currentParticipantService, IMapper mapper) { this._mediator = mediator; this._dbContextFactory = dbContextFactory; this._currentParticipantService = currentParticipantService; this._mapper = mapper; }
public JoinPokerSessionCommandValidator(IPokerTimeDbContextFactory pokerTimeDbContext, IPassphraseService passphraseService) { this._pokerTimeDbContext = pokerTimeDbContext; this._passphraseService = passphraseService; this.RuleFor(e => e.Name).NotEmpty().MaximumLength(256); this.RuleFor(e => e.Color).NotEmpty() .WithMessage("Please select a color") .Matches("^#?([A-F0-9]{2}){3}$", RegexOptions.IgnoreCase) .WithMessage("Please select a color"); this.RuleFor(e => e.Passphrase) .NotEmpty() .When(x => x.JoiningAsFacilitator); // Passphrase validation this.RuleFor(e => e.Passphrase). Must((obj, passphrase) => this.MustBeAValidPassphrase(obj.SessionId, obj.JoiningAsFacilitator, obj.Passphrase)) .WithMessage("This passphrase is not valid. Please try again."); }
public GetEstimationsOverviewQueryHandler(IPokerTimeDbContextFactory dbContextFactory, IMapper mapper) { this._dbContextFactory = dbContextFactory; this._mapper = mapper; }
public InitiateFinishStageCommandHandler(IPokerTimeDbContextFactory pokerTimeDbContext, ISessionStatusUpdateDispatcher sessionStatusUpdateDispatcher) : base(pokerTimeDbContext, sessionStatusUpdateDispatcher) { }
public GetSymbolSetsQueryHandler(IPokerTimeDbContextFactory dbContextFactory, IMapper mapper) { this._dbContextFactory = dbContextFactory; this._mapper = mapper; }