public YieldController(IYieldService yieldService, IWarehouseService warehouseService, IHttpContextAccessor httpContextAccessor) { _yieldService = yieldService; _warehouseService = warehouseService; _httpContextAccessor = httpContextAccessor; userId = _httpContextAccessor.HttpContext.User.FindFirst(ClaimTypes.NameIdentifier).Value; }
public ProductController(ISeedService seedService, IFertilizerService fertilizerService, IYieldService yieldService, IPesticideService pesticideService, IHttpContextAccessor httpContextAccessor) { _seedService = seedService; _fertilizerService = fertilizerService; _yieldService = yieldService; _pesticideService = pesticideService; _httpContextAccessor = httpContextAccessor; }
private async Task <string> CoroutineBuildString(int i, IYieldService <bool, string, string> yieldService) { await yieldService.Yield("Building string [" + i + "]"); string str = "[" + i + "]:" + (char)((int)'A' + i); await yieldService.Yield("String built."); return(str); }
private async Task<string> CoroutineBuildString(int i, IYieldService<bool, string, string> yieldService) { await yieldService.Yield("Building string [" + i + "]"); string str = "[" + i + "]:" + (char)((int)'A' + i); await yieldService.Yield("String built."); return str; }
private async Task <bool> Coroutine1(IYieldService <bool, string, bool> yieldService) { foreach (int i in Enumerable.Range(0, 10)) { string si = await yieldService.YieldFrom <string>(y2 => CoroutineBuildString(i, y2)); await yieldService.Yield("Received completed string: " + si); } return(true); }
private async Task<bool> Coroutine1(IYieldService<bool, string, bool> yieldService) { foreach(int i in Enumerable.Range(0, 10)) { string si = await yieldService.YieldFrom<string>(y2 => CoroutineBuildString(i, y2)); await yieldService.Yield("Received completed string: " + si); } return true; }
public IncomeRequestHandler(BankDbContext context, IYieldService yieldService) { _context = context; _yieldService = yieldService; }