public DbMigratorHostedService(IServiceProvider serviceProvider,
                                ILoggingService logger)
 {
     Console.WriteLine("Initialising hosted service");
     _serviceProvider = serviceProvider;
     //_lifetime = lifetime;
     _logging = new SourcedLoggingService(logger, "dbmigrator");
 }
Exemple #2
0
 public JailConfigCommands(DiscordSocketClient client, ILoggingService logging, IJailSettingsRepository jailSettings, IGuildConfigRepository repo, InteractivityService interactivity)
 {
     _client        = client.Rest;
     _jailSettings  = jailSettings;
     _repo          = repo;
     _interactivity = interactivity;
     _logging       = new SourcedLoggingService(logging, "jailconfig");
 }
Exemple #3
0
 public GuildConfigCommands(InteractivityService interactivity, IGuildConfigRepository repo, ILoggingService logging, DiscordSocketClient client)
 {
     logging.Info("Initialising Guild Config Command Service");
     _interactivity = interactivity;
     _repo          = repo;
     _logging       = new SourcedLoggingService(logging, "ConfigCmds");
     _client        = client.Rest;
 }
 public ReactionRoleCommands(InteractivityService interactivity, IGuildConfigRepository repo, ILoggingService logging, DiscordSocketClient client, ReactionRoleService rrService, IReactionRoleRuleRepository rrRepo)
 {
     logging.Info("Initialising Reaction Role Command Service");
     _interactivity = interactivity;
     _repo          = repo;
     _rrService     = rrService;
     _rrRepo        = rrRepo;
     _logging       = new SourcedLoggingService(logging, "RRCmds");
     _client        = client.Rest;
 }
Exemple #5
0
 public JailCommands(InteractivityService interactivity, IGuildConfigRepository repo, IJailSettingsRepository jailSettings, ILoggingService logging, DiscordSocketClient client, IJailDataRepository jailData, UnjailService unjail)
 {
     _interactivity = interactivity;
     _repo          = repo;
     _jailSettings  = jailSettings;
     _jailData      = jailData;
     _unjail        = unjail;
     _logging       = new SourcedLoggingService(logging, "Jail");
     _client        = client.Rest;
     _logging.Info("Jail commands setup");
 }
Exemple #6
0
 // Retrieve client and CommandService instance via ctor
 public CommandHandler(DiscordSocketClient client, CommandService commands, ILoggingService logging)
 {
     _commands = commands;
     _client   = client;
     _logging  = new SourcedLoggingService(logging, "CmdHandler");
 }