public VehicleInfractionController( IVehicleService vehicleService, IInfractionService infractionService, IVehicleInfractionService vehicleInfractionService) { this.vehicleService = vehicleService; this.infractionService = infractionService; this.vehicleInfractionService = vehicleInfractionService; }
public VehicleInfractionService( IVehicleInfractionRepository vehicleInfractionRepository, IVehicleService vehicleService, IDriverService driverService, IInfractionService infractionService) { this.vehicleInfractionRepository = vehicleInfractionRepository; this.vehicleService = vehicleService; this.driverService = driverService; this.infractionService = infractionService; }
private async Task Setup() { var redisSetup = new Setup(this.logger); this.logger.Information("Initializing the services setup..."); services = new ServiceCollection().AddStackExchangeRedisExtensions <NewtonsoftSerializer>(redisSetup.RedisConfiguration); serviceProvider = services.BuildServiceProvider(); redis = serviceProvider.GetService <IRedisDatabase>(); reactionService = new ReactionService(this.logger, redis); infractionService = new InfractionService(this.logger, redis); logService = new LogService(this.logger, redis); services.AddSingleton(this.logger) .AddSingleton(reactionService) .AddSingleton(infractionService) .AddSingleton(logService); serviceProvider = services.BuildServiceProvider(); this.logger.Information("Successfully setup the services."); config = await redis.GetAsync <Config>(RedisKeyNaming.Config).ConfigureAwait(true); if (config == null || string.IsNullOrWhiteSpace(config.Token)) { this.logger.Information("Initializing the bot token setup..."); Console.Write("Your bot token: "); var token = Console.ReadLine(); if (config == null) { config = new Config() { Token = token }; await redis.AddAsync(RedisKeyNaming.Config, config).ConfigureAwait(true); } else if (string.IsNullOrWhiteSpace(config.Token)) { config.Token = token; await redis.ReplaceAsync(RedisKeyNaming.Config, config).ConfigureAwait(true); } this.logger.Information("Successfully set the bot token into the database."); } else { this.logger.Information("Discord token is already set and will be used from the database."); } OpenCL.IsEnabled = false; this.logger.Information("Disabled GPU acceleration."); await Task.CompletedTask.ConfigureAwait(true); }
public KickCommand(ILogger <KickCommand> logger, IDatabaseService dbService, IInfractionService incractionService) => (_logger, _dbService, _infractionService) = (logger, dbService, incractionService);
public InfractionsController(IInfractionService infractionService) { _infractionService = infractionService; }
public Kick(ILogger logger, IRedisDatabase redis, IInfractionService infractionService) { this.logger = logger; this.redis = redis; this.infractionService = infractionService; }
public TempMuteCommand(ConfigService dbService, IInfractionService infractionService) { _dbService = dbService; _infractionService = infractionService; }
public ServiceLocatorSchool(IServiceLocatorMaster serviceLocatorMaster) : base(serviceLocatorMaster.Context) { this.serviceLocatorMaster = serviceLocatorMaster; personService = new PersonService(this); addressSerivce = new AddressService(this); gradeLevelService = new GradeLevelService(this); markingPeriodService = new MarkingPeriodService(this); classService = new ClassService(this); schoolYearService = new SchoolYearService(this); announcementQnAService = new AnnouncementQnAService(this); announcementAttachmentService = new AnnouncementAttachmentService(this); phoneService = new PhoneService(this); privateMessageService = new PrivateMessageService(this); roomService = new RoomService(this); periodService = new PeriodService(this); calendarDateService = new CalendarDateService(this); dayTypeService = new DayTypeService(this); classPeriodService = new ClassPeriodService(this); notificationService = new NotificationService(this); attendanceReasonService = new AttendanceReasonService(this); attendanceService = new AttendanceService(this); studentParentService = new StudentParentService(this); studentAnnouncementService = new StudentAnnouncementService(this); classClassAnnouncementTypeService = new ClassClassAnnouncementTypeService(this); infractionService = new InfractionService(this); applicationSchoolService = new ApplicationSchoolService(this); disciplineService = new DisciplineService(this); gradingStatisticService = new GradingStatisticService(this); schoolService = new SchoolService(this); schoolPersonService = new SchoolPersonService(this); standardService = new StandardService(this); alphaGradeService = new AlphaGradeService(this); alternateScoreService = new AlternateScoreService(this); gradingPeriodService = new GradingPeriodService(this); syncService = new SyncService(this); gradingStandardService = new GradingStandardService(this); reportService = new ReportingService(this); gradingCommentService = new GradingCommentService(this); gradingScaleService = new GradingScaleService(this); classroomOptionService = new ClassroomOptionService(this); personEmailService = new PersonEmailService(this); schoolDbService = new DbService(Context != null ? Context.SchoolConnectionString : null); scheduledTimeSlotService = new ScheduledTimeSlotService(this); studentService = new StudentService(this); staffService = new StaffService(this); userSchoolService = new UserSchoolService(this); bellScheduleService = new BellScheduleService(this); practiceGradeService = new PracticeGradeService(this); attendanceMonthService = new AttendanceMonthService(this); gradedItemService = new GradedItemService(this); announcementAttributeService = new AnnouncementAttributeService(this); announcementAssignedAttributeService = new AnnouncementAssignedAttributeService(this); contactService = new ContactService(this); teacherCommentService = new TeacherCommentService(this); dbMaintenanceService = new DbMaintenanceService(this); groupService = new GroupService(this); courseTypeService = new CourseTypeService(this); settingsService = new SettingsService(this); lpGalleryCategoryService = new LPGalleryCategoryService(this); lessonPlanService = new LessonPlanService(this); classAnnouncementService = new ClassAnnouncementService(this); adminAnnouncementService = new AdminAnnouncementService(this); announcementFetchService = new AnnouncementFetchService(this); leService = new LEService(this); attachementService = new AttachmentService(this); personSettingService = new PersonSettingService(this); studentCustomAlertDetailService = new StudentCustomAlertDetailService(this); panoramaSettingsService = new PanoramaSettingsService(this); standardizedTestService = new StandardizedTestService(this); supplementalAnnouncementService = new SupplementalAnnouncementService(this); ethnicityService = new EthnicityService(this); languageService = new LanguageService(this); countryService = new CountryService(this); announcementCommentService = new AnnouncementCommentService(this); appSettingService = new AppSettingService(this); limitedEnglishService = new LimitedEnglishService(this); schoolProgramService = new SchoolProgramService(this); studentSchoolProgramService = new StudentSchoolProgramService(this); mealTypeService = new MealTypeService(this); lunchCountService = new LunchCountService(this); }
public InfractionController(IInfractionService infractionService) { this.infractionService = infractionService; }