public JobGroupsController(JobGroupsControllerUtils utils, UnrealizedPnlSeriesControllerUtils unrealizedPnlSeriesControllerUtils, TradeGenericMetric2SeriesControllerUtils tradeGenericMetric2SeriesControllerUtils, JobsControllerUtils jobsControllerUtils) { this.jobsControllerUtils = jobsControllerUtils; this.utils = utils; this.tradeGenericMetric2SeriesControllerUtils = tradeGenericMetric2SeriesControllerUtils; this.unrealizedPnlSeriesControllerUtils = unrealizedPnlSeriesControllerUtils; }
public JobGroupTabsViewComponent(JobGroupsControllerUtils utils) { this.utils = utils; }
public static void AddControllerUtils(this IServiceCollection services, IConfigurationRoot config) { services.AddSingleton((serviceProvider) => { var actioner = serviceProvider.GetService <BacktestJobActioner>(); return(new JobsControllerUtils(actioner)); }); services.AddSingleton((serviceProvider) => { var actioner = serviceProvider.GetService <BacktestJobGroupActioner>(); JobsControllerUtils jobsControllerUtils = serviceProvider.GetService <JobsControllerUtils>(); AllTradesConnector allTradesConnector = serviceProvider.GetService <AllTradesConnector>(); TradeGenericMetric2SeriesConnector tradeGenericMetric2SeriesConnector = serviceProvider.GetService <TradeGenericMetric2SeriesConnector>(); UnrealizedPnlSeriesConnector unrealizedPnlSeriesConnector = serviceProvider.GetService <UnrealizedPnlSeriesConnector>(); return(new JobGroupsControllerUtils(actioner, jobsControllerUtils, allTradesConnector, tradeGenericMetric2SeriesConnector, unrealizedPnlSeriesConnector)); }); services.AddSingleton((serviceProvider) => { var actioner = serviceProvider.GetService <UnrealizedPnlSerieActioner>(); return(new UnrealizedPnlSeriesControllerUtils(actioner)); }); services.AddSingleton((serviceProvider) => { var actioner = serviceProvider.GetService <TradeGenericMetric2SerieActioner>(); return(new TradeGenericMetric2SeriesControllerUtils(actioner)); }); services.AddSingleton((serviceProvider) => { string stratFilesUploadDirectory = config.GetValue <string>("StratFileDropDir") ?? Path.GetTempPath(); JobsControllerUtils jobsControllerUtils = serviceProvider.GetService <JobsControllerUtils>(); JobGroupsControllerUtils jobGroupsControllerUtils = serviceProvider.GetService <JobGroupsControllerUtils>(); return(new CreateJobControllerUtils(stratFilesUploadDirectory, jobsControllerUtils, jobGroupsControllerUtils)); }); services.AddSingleton((serviceProvider) => { CreateJobControllerUtils createJobControllerUtils = serviceProvider.GetService <CreateJobControllerUtils>(); string excelJobFilesUploadDirectory = config.GetValue <string>("ExcelJobFileDropDir") ?? Path.GetTempPath(); string stratFilesUploadDirectory = config.GetValue <string>("StratFileDropDir") ?? Path.GetTempPath(); return(new CreateJobExcelControllerUtils(createJobControllerUtils, excelJobFilesUploadDirectory, stratFilesUploadDirectory)); }); services.AddSingleton((serviceProvider) => { JobsControllerUtils jobsControllerUtils = serviceProvider.GetService <JobsControllerUtils>(); return(new WorkersControllerUtils(jobsControllerUtils)); }); services.AddSingleton((serviceProvider) => { JobsControllerUtils jobsControllerUtils = serviceProvider.GetService <JobsControllerUtils>(); return(new AlertsControllerUtils(jobsControllerUtils)); }); services.AddSingleton((serviceProvider) => { JobsControllerUtils jobsControllerUtils = serviceProvider.GetService <JobsControllerUtils>(); return(new OrdersControllerUtils(jobsControllerUtils)); }); services.AddSingleton((serviceProvider) => { JobsControllerUtils jobsControllerUtils = serviceProvider.GetService <JobsControllerUtils>(); return(new PositionsControllerUtils(jobsControllerUtils)); }); services.AddSingleton((serviceProvider) => { JobsControllerUtils jobsControllerUtils = serviceProvider.GetService <JobsControllerUtils>(); JobGroupsControllerUtils jobGroupsControllerUtils = serviceProvider.GetService <JobGroupsControllerUtils>(); return(new TradesControllerUtils(jobsControllerUtils, jobGroupsControllerUtils)); }); services.AddSingleton((serviceProvider) => { JobsControllerUtils jobsControllerUtils = serviceProvider.GetService <JobsControllerUtils>(); return(new StatusesControllerUtils(jobsControllerUtils)); }); services.AddSingleton((serviceProvider) => { string serverName = config.GetValue <string>("ServerName") ?? "BacktesterServer"; return(new InfoControllerUtils(serverName, DateTimeOffset.Now)); }); }
public TradesController(JobGroupsControllerUtils jobGroupsControllerUtils, TradesControllerUtils tradesControllerUtils) { this.jobGroupsControllerUtils = jobGroupsControllerUtils; this.tradesControllerUtils = tradesControllerUtils; }
public CreateJobController(CreateJobControllerUtils createJobControllerUtils, JobGroupsControllerUtils jobGroupsControllerUtils) { this.createJobControllerUtils = createJobControllerUtils; this.jobGroupsControllerUtils = jobGroupsControllerUtils; }
public HomeController(JobGroupsControllerUtils jobGroupsControllerUtils, WorkersControllerUtils workersControllerUtils) { this.jobGroupsControllerUtils = jobGroupsControllerUtils; this.workersControllerUtils = workersControllerUtils; }
public JobGroupsApiController(JobGroupsControllerUtils utils) { this.utils = utils; }