コード例 #1
0
 public DucCommandHandler(
     IGameServersRepository gameServersRepository,
     IRconClientFactory rconClientFactory) : base(new[] { "!duc" })
 {
     _gameServersRepository = gameServersRepository ?? throw new ArgumentNullException(nameof(gameServersRepository));
     _rconClientFactory     = rconClientFactory ?? throw new ArgumentNullException(nameof(rconClientFactory));
 }
コード例 #2
0
 public FuckYouCommandHandler(
     ILogger <FuckYouCommandHandler> logger,
     IGameServersRepository gameServersRepository,
     IGameServerStatusRepository gameServerStatusRepository,
     IRconClientFactory rconClientFactory) : base(new [] { "!fu" })
 {
     _logger = logger ?? throw new ArgumentNullException(nameof(logger));
     _gameServersRepository      = gameServersRepository ?? throw new ArgumentNullException(nameof(gameServersRepository));
     _gameServerStatusRepository = gameServerStatusRepository ?? throw new ArgumentNullException(nameof(gameServerStatusRepository));
     _rconClientFactory          = rconClientFactory ?? throw new ArgumentNullException(nameof(rconClientFactory));
 }
コード例 #3
0
 public ServerAdminController(
     IAuthorizationService authorizationService,
     IGameServersRepository gameServersRepository,
     IGameServerStatusRepository gameServerStatusRepository,
     IRconClientFactory rconClientFactory,
     IChatLogsRepository chatLogsRepository,
     IPlayersRepository playersRepository)
 {
     _authorizationService       = authorizationService ?? throw new ArgumentNullException(nameof(authorizationService));
     _gameServersRepository      = gameServersRepository ?? throw new ArgumentNullException(nameof(gameServersRepository));
     _gameServerStatusRepository = gameServerStatusRepository ?? throw new ArgumentNullException(nameof(gameServerStatusRepository));
     _rconClientFactory          = rconClientFactory ?? throw new ArgumentNullException(nameof(rconClientFactory));
     _chatLogsRepository         = chatLogsRepository ?? throw new ArgumentNullException(nameof(chatLogsRepository));
     _playersRepository          = playersRepository ?? throw new ArgumentNullException(nameof(playersRepository));
 }
コード例 #4
0
 public MapPopularityCommandHandler(
     ILogger <MapPopularityCommandHandler> logger,
     IGameServersRepository gameServersRepository,
     IMapPopularityRepository mapPopularityRepository,
     IRconClientFactory rconClientFactory,
     IGameServerStatusRepository gameServerStatusRepository,
     IPlayersRepository playersRepository) : base(new[] { "!like", "!dislike" })
 {
     _logger = logger ?? throw new ArgumentNullException(nameof(logger));
     _gameServersRepository      = gameServersRepository ?? throw new ArgumentNullException(nameof(gameServersRepository));
     _mapPopularityRepository    = mapPopularityRepository ?? throw new ArgumentNullException(nameof(mapPopularityRepository));
     _rconClientFactory          = rconClientFactory ?? throw new ArgumentNullException(nameof(rconClientFactory));
     _gameServerStatusRepository = gameServerStatusRepository ?? throw new ArgumentNullException(nameof(gameServerStatusRepository));
     _playersRepository          = playersRepository ?? throw new ArgumentNullException(nameof(playersRepository));
 }
コード例 #5
0
 public GameServerClient(ILogger logger, IQueryClientFactory queryClientFactory, IRconClientFactory rconClientFactory)
 {
     _logger             = logger ?? throw new ArgumentNullException(nameof(logger));
     _queryClientFactory = queryClientFactory ?? throw new ArgumentNullException(nameof(queryClientFactory));
     _rconClientFactory  = rconClientFactory ?? throw new ArgumentNullException(nameof(rconClientFactory));
 }