Example #1
0
 public ChatService(
     ILogger <ChatService> logger,
     CacheService cacheService,
     IOptionsSnapshot <RestrictionConfig> restrictionConfig,
     ITelegramBotClient botClient,
     BotService botService,
     MessageHistoryService messageHistoryService,
     SettingsService settingsService
     )
 {
     _logger                = logger;
     _botClient             = botClient;
     _botService            = botService;
     _messageHistoryService = messageHistoryService;
     _cacheService          = cacheService;
     _restrictionConfig     = restrictionConfig.Value;
     _settingsService       = settingsService;
 }
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="restrictionConfig"></param>
 /// <param name="logger"></param>
 /// <param name="cacheService"></param>
 /// <param name="botService"></param>
 /// <param name="chatService"></param>
 /// <param name="settingsService"></param>
 /// <param name="botClient"></param>
 public PrivilegeService(
     IOptionsSnapshot <RestrictionConfig> restrictionConfig,
     ILogger <PrivilegeService> logger,
     CacheService cacheService,
     BotService botService,
     ChatService chatService,
     SettingsService settingsService,
     ITelegramBotClient botClient,
     WTelegramApiService wTelegramApiService
     )
 {
     _logger              = logger;
     _cacheService        = cacheService;
     _botService          = botService;
     _chatService         = chatService;
     _settingsService     = settingsService;
     _botClient           = botClient;
     _wTelegramApiService = wTelegramApiService;
     _restrictionConfig   = restrictionConfig.Value;
 }
Example #3
0
 public JobsService(
     ILogger <JobsService> logger,
     IOptionsSnapshot <EventLogConfig> eventLogConfig,
     IOptions <RestrictionConfig> restrictionConfig,
     IBackgroundJobClient backgroundJobClient,
     IRecurringJobManager recurringJobManager,
     StepHistoriesService stepHistoriesService,
     ChatService chatService,
     ITelegramBotClient botClient,
     SettingsService settingsService
     )
 {
     _eventLogConfig       = eventLogConfig.Value;
     _restrictionConfig    = restrictionConfig.Value;
     _logger               = logger;
     _backgroundJobClient  = backgroundJobClient;
     _recurringJobManager  = recurringJobManager;
     _stepHistoriesService = stepHistoriesService;
     _chatService          = chatService;
     _botClient            = botClient;
     _settingsService      = settingsService;
 }
Example #4
0
 /// <summary>
 /// Instantiate class
 /// </summary>
 /// <param name="restrictionConfigOpt"></param>
 public ChatRestrictionModule(IOptionsSnapshot <RestrictionConfig> restrictionConfigOpt)
 {
     _restrictionConfig = restrictionConfigOpt.Value;
 }