/// <summary> /// Construct service with dependencies from database and other services. /// </summary> /// <param name="_context"> /// Database context. /// </param> /// <param name="twilioService"> /// Service for accessing SMS. /// </param> /// <param name="alpha"> /// Service for getting prices. /// </param> /// <param name="limitCount"> /// Service for limiting requests made by users. /// </param> public WatchService(IStockDbContext _context, ITwilioService twilioService, AlphaVantage alpha, ILimitCount limitCount) { context = _context; twilio = twilioService; alphaVantage = alpha; limit = limitCount; }
/// <summary> /// Initialize the service with database and Twilio credentials /// </summary> /// <param name="_context"> /// Database context for checking user records. /// </param> /// <param name="ACCT_SID"> /// Account Service ID for API. /// </param> /// <param name="AUTH_TOKEN"> /// Authentication Token for API. /// </param> /// <param name="SRV_SID"> /// Service ID for Notifications. /// </param> public TwilioService(IStockDbContext _context, string ACCT_SID, string AUTH_TOKEN, string SRV_SID) { context = _context; accountSid = ACCT_SID; authToken = AUTH_TOKEN; serviceSid = SRV_SID; }
public StockRepository(IStockDbContext dbContext, IMapper mapper) { this.dbContext = dbContext; this.mapper = mapper; }
public StockActionUniqueChecker(IStockDbContext stockDbContext) { _stockDbContext = stockDbContext; }
public InitializeStockCommandHandler(IStockDbContext stockDbContext, IStockActionUniqueChecker stockActionUniqueChecker) { _stockDbContext = stockDbContext; _stockActionUniqueChecker = stockActionUniqueChecker; }
public StockSnapshotUniqueChecker(IStockDbContext stockDbContext) { _stockDbContext = stockDbContext; }
public CreateStockReadModelCommandHandler(IStockDbContext stockDbContext, IStockUniqueChecker stockUniqueChecker) { _stockDbContext = stockDbContext; _stockUniqueChecker = stockUniqueChecker; }
public QueryStockCommandHandler(IStockDbContext stockDbContext) { _stockDbContext = stockDbContext; }
public RemoveFromStockCommandHandler(IStockActionUniqueChecker stockActionUniqueChecker, IStockDbContext stockDbContext) { _stockActionUniqueChecker = stockActionUniqueChecker; _stockDbContext = stockDbContext; }
public StockInitializedEvent_CreateStockSnapshot(IStockSnapshotUniqueChecker snapshotUniqueChecker, IStockDbContext stockDbContext) { _snapshotUniqueChecker = snapshotUniqueChecker; _stockDbContext = stockDbContext; }
public MockTwilioService(IStockDbContext context, string ACCT_SID, string AUTH_TOKEN, string SRV_SID) : base(context, ACCT_SID, AUTH_TOKEN, SRV_SID) { }
public StocksService(IStockDbContext liteDbContext) { _database = liteDbContext.Database; }
public UpdateAvailableStockCountReadModelCommandHandler(IStockDbContext stockDbContext) { _stockDbContext = stockDbContext; }
public QueryCompanyService(IStockDbContext _context) { context = _context; }
public StockRepository(IStockDbContext context) { dbContext = context; }
public StockIncreasedEvent_UpdateStockSnapshot(IStockDbContext stockDbContext) { _stockDbContext = stockDbContext; }
public LimitCountService(IStockDbContext _context) { context = _context; }
public MockWatchService(IStockDbContext context, ITwilioService twilio, AlphaVantage alpha, ILimitCount limitCount) : base(context, twilio, alpha, limitCount) { }
public AddToStockCommandHandler(IStockActionUniqueChecker stockActionUniqueChecker, IStockDbContext stockDbContext) { _stockActionUniqueChecker = stockActionUniqueChecker; _stockDbContext = stockDbContext; }
public RollbackDecreaseFromStockCommandHandler(IStockDbContext stockDbContext, IDomainMessageBroker domainMessageBroker) { _stockDbContext = stockDbContext; _domainMessageBroker = domainMessageBroker; }