public HomeController(IUserManager userManager , ILearningRecord learningRecord , ICourseManager courseManager , ILearningDesignate learningDesignate , IExamTestManager examTestManager , ISurveyManager surveyManager , ISortManager knowSortManager , IResourceManager resourceManager , IPromotionWayManager promotionWayManager , IExaminationManager examinationManager , ITrainLearningManager trainLearningManager , IUserMessageManager userMessageManager) { _userManager = userManager; _learningRecord = learningRecord; _courseManager = courseManager; _learningDesignate = learningDesignate; _examTestManager = examTestManager; _surveyManager = surveyManager; _knowSortManager = knowSortManager; _resourceManager = resourceManager; _promotionWayManager = promotionWayManager; _examinationManager = examinationManager; _trainLearningManager = trainLearningManager; _userMessageManager = userMessageManager; }
public static void RegisterAll(ISortManager <Product> sortManager, IPopularityService popularityService) { sortManager.RegisterPlainSorter("low", (x, y) => x.Price.CompareTo(y.Price)); sortManager.RegisterPlainSorter("high", (x, y) => y.Price.CompareTo(x.Price)); sortManager.RegisterPlainSorter("ascending", (x, y) => x.Name.CompareTo(y.Name)); sortManager.RegisterPlainSorter("descending", (x, y) => y.Name.CompareTo(x.Name)); sortManager.RegisterComplexSorter("recommended", new ProductRecommendedSort(popularityService)); }
public KnowledgeManagerController(ISortManager sortManager , IResourceManager resourceManager , IUserManager userManager) { _sortManager = sortManager; _resourceManager = resourceManager; _userManager = userManager; }
public KnowledgeCenterController(IResourceManager resourceManager , IReadRecordManager readRecordManager , ITagsManager tagsManager , ISortManager sortManager , IDeptManager deptManager) { _sortManager = sortManager; _resourceManager = resourceManager; _readRecordManager = readRecordManager; _tagsManager = tagsManager; _deptManager = deptManager; }
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline. public void Configure(IApplicationBuilder app, IHostingEnvironment env, ISortManager <Product> sortManager, IPopularityService popularityService) { if (env.IsDevelopment()) { app.UseDeveloperExceptionPage(); } else { // The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts. app.UseHsts(); } app.UseHttpsRedirection(); app.UseMvc(); ProductSortRegister.RegisterAll(sortManager, popularityService); }
public void Setup() { _sut = new SortManager(); }
public void Init() { _mockFileManager = new Mock <IFileManager>(); _sut = new SortManager(_mockFileManager.Object); }
public ProductService(IConfiguration configuration, ISortManager <Product> sortManager) { _configuration = configuration; _sortManager = sortManager; }